rpms/e2tools/devel e2tools-printf-lld-64bit.patch, 1.1, 1.2 e2tools.spec, 1.3, 1.4

Hans Ulrich Niedermann (ndim) fedora-extras-commits at redhat.com
Sun Dec 9 02:30:24 UTC 2007


Author: ndim

Update of /cvs/pkgs/rpms/e2tools/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv26446

Modified Files:
	e2tools-printf-lld-64bit.patch e2tools.spec 
Log Message:
* Sun Dec  9 2007 Hans Ulrich Niedermann <hun at n-dimensional.de> - 0.0.16-9
- Use format string macro from inttypes.h and uint64_t (#349851).


e2tools-printf-lld-64bit.patch:

Index: e2tools-printf-lld-64bit.patch
===================================================================
RCS file: /cvs/pkgs/rpms/e2tools/devel/e2tools-printf-lld-64bit.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- e2tools-printf-lld-64bit.patch	8 Dec 2007 22:28:21 -0000	1.1
+++ e2tools-printf-lld-64bit.patch	9 Dec 2007 02:30:19 -0000	1.2
@@ -1,17 +1,29 @@
-diff -ru e2tools-0.0.16/ls.c e2tools-0.0.16-lld/ls.c
---- e2tools-0.0.16/ls.c	2007-12-08 22:14:50.000000000 +0100
-+++ e2tools-0.0.16-lld/ls.c	2007-12-08 22:15:25.000000000 +0100
-@@ -657,8 +657,13 @@
+Caution: Checking __WORDSIZE == 64 is not enough.
+
+ On x86_64, << printf("%7" PRIu64, (__u64)1); >> lets gcc throw a warning.
+ __u64 seems to be a long int; uint64_t a long long int; PRIu64 "llu".
+ So __u64 is not compatible with PRIu64, even though it is a 64bit value.
+
+diff -ru e2tools-0.0.16-orig/ls.c e2tools-0.0.16-lld/ls.c
+--- e2tools-0.0.16-orig/ls.c	2007-12-08 23:57:40.000000000 +0100
++++ e2tools-0.0.16-lld/ls.c	2007-12-09 03:10:24.000000000 +0100
+@@ -44,6 +44,8 @@
+ #include "e2tools.h"
+ #include "elist.h"
+ #include <regex.h>
++#include <stdint.h>
++#include <inttypes.h>
+ 
+ /*
+  * list directory
+@@ -657,8 +659,8 @@
    if (LINUX_S_ISDIR(info->inode.i_mode))
      printf("%7d", info->inode.i_size);
    else
-+#if __WORDSIZE == 64
-+    printf("%7ld", info->inode.i_size |
-+           ((__u64)info->inode.i_size_high << 32));
-+#else
-     printf("%7lld", info->inode.i_size |
-            ((__u64)info->inode.i_size_high << 32));
-+#endif
+-    printf("%7lld", info->inode.i_size |
+-           ((__u64)info->inode.i_size_high << 32));
++    printf("%7" PRIu64, (uint64_t)(info->inode.i_size |
++				  ((__u64)info->inode.i_size_high << 32)));
    printf(" %s %s\n", datestr, info->name);
  
  } /* end of long_disp */ 


Index: e2tools.spec
===================================================================
RCS file: /cvs/pkgs/rpms/e2tools/devel/e2tools.spec,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- e2tools.spec	8 Dec 2007 22:28:21 -0000	1.3
+++ e2tools.spec	9 Dec 2007 02:30:19 -0000	1.4
@@ -1,6 +1,6 @@
 Name:           e2tools
 Version:        0.0.16
-Release:        8%{?dist}
+Release:        9%{?dist}
 Summary:        Manipulate files in unmounted ext2/ext3 filesystems
 
 Group:          Applications/System
@@ -100,6 +100,9 @@
 
 
 %changelog
+* Sun Dec  9 2007 Hans Ulrich Niedermann <hun at n-dimensional.de> - 0.0.16-9
+- Use format string macro from inttypes.h and uint64_t (#349851).
+
 * Sat Dec  8 2007 Hans Ulrich Niedermann <hun at n-dimensional.de> - 0.0.16-8
 - Special __u64 formatstring on 64bit platforms (#349851).
 - Reintroduce -Werror for all platforms.




More information about the fedora-extras-commits mailing list