Hello,

Don't set hint_byte to EXTENT_MAP_INLINE when 'end == extent_end' or
'start == key.offset' . The inline extent will be truncated in these
cases.

Regards
YZ
---
diff -r 2456df534a5f file.c
--- a/file.c    Thu Nov 01 19:45:34 2007 -0400
+++ b/file.c    Sat Nov 03 20:02:59 2007 +0800
@@ -475,7 +475,7 @@ next_slot:
                } else
                        search_start = extent_end;

-               if (end <= extent_end && start >= key.offset && found_inline) {
+               if (end < extent_end && start > key.offset && found_inline) {
                        *hint_byte = EXTENT_MAP_INLINE;
                }
                if (end < extent_end && end >= key.offset) {

_______________________________________________
Btrfs-devel mailing list
[email protected]
http://oss.oracle.com/mailman/listinfo/btrfs-devel

Reply via email to