]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
* src/fiemap.h (struct fiemap.fm_extents): Change size to 1.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 15 Jul 2011 05:06:46 +0000 (22:06 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 15 Jul 2011 05:08:04 +0000 (22:08 -0700)
This is for portability to non-GCC C89 and C99 compilers.
Original problem, on NonStop, reported by Joachim Schmitz in
<http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9077>.

src/fiemap.h

index 1938c749ec808dfb552c72efd4ad9f6602df60a6..e7243b41b5e5a3f60a4588c3ae150a7aec25c4ae 100644 (file)
@@ -51,8 +51,9 @@ struct fiemap
 
   uint32_t fm_reserved;
 
-  /* Array of mapped extents(out).  */
-  struct fiemap_extent fm_extents[0];
+  /* Array of mapped extents(out).
+     The actual size is given by fm_extent_count.  */
+  struct fiemap_extent fm_extents[1];
 };
 
 /* The maximum offset can be mapped for a file.  */