On 5/22/06, Aidan Kehoe <kehoea(a)parhasard.net> wrote:
APPROVE COMMIT
SUPERSEDES 17501.60891.531339.727372(a)parhasard.net
NOTE: This patch has been committed.
src/ChangeLog addition:
2006-05-22 Aidan Kehoe <kehoea(a)parhasard.net>
* file-coding.c (output_bytes_in_ascii_and_hex):
Pass stderr_out internally-formatted data, don't use an external
format.
XEmacs Trunk source patch:
Diff command: cvs -q diff -u
Files affected: src/file-coding.c
Index: src/file-coding.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/file-coding.c,v
retrieving revision 1.52
diff -u -u -r1.52 file-coding.c
--- src/file-coding.c 2006/03/26 13:05:17 1.52
+++ src/file-coding.c 2006/05/22 20:24:00
@@ -3370,6 +3370,8 @@
UExtbyte *ascii = alloca_array (UExtbyte, n + 1);
UExtbyte *hex = alloca_array (UExtbyte, 3 * n + 1);
int i;
+ DECLARE_EISTRING (eistr_ascii);
+ DECLARE_EISTRING (eistr_hex);
for (i = 0; i < n; i++)
{
@@ -3384,7 +3386,11 @@
}
ascii[i] = '\0';
hex[3 * i - 1] = '\0';
- stderr_out ("%s %s", ascii, hex);
+
+ eicpy_ext(eistr_hex, hex, Qbinary);
+ eicpy_ext(eistr_ascii, ascii, Qbinary);
+
+ stderr_out ("%s %s", eidata(eistr_ascii), eidata(eistr_hex));
}
#endif /* DEBUG_XEMACS */
Aidan -
Unfortunately, the 21.5 build is now failing on windows, this is using
Visual Studio 6.0.
e:\cygwin\usr\local\src\xemacs-21.5-2006-05-23\src\file-coding.c(3390)
: error C2440: 'initializing' : cannot convert from 'unsigned char *'
to 'const char *'
Types pointed to are unrelated; conversion requires
reinterpret_cast, C-style cast or function-style cast
e:\cygwin\usr\local\src\xemacs-21.5-2006-05-23\src\file-coding.c(3391)
: error C2440: 'initializing' : cannot convert from 'unsigned char *'
to 'const char *'
Types pointed to are unrelated; conversion requires
reinterpret_cast, C-style cast or function-style cast
NMAKE: fatal error U1077: 'cl' : return code '0x2'
The cygwin build, like my linux builds at home is working, but I
suspect that there is a new error:
--- xemacs-21.5-2006-05-16-mule/mk.out
+++ xemacs-21.5-2006-05-23-mule/mk.out
@@ -126,0 +127,3 @@
+/usr/local/src/xemacs-21.5-2006-05-23-mule/src/file-coding.c: In
function 'output_bytes_in_ascii_and_hex':
+/usr/local/src/xemacs-21.5-2006-05-23-mule/src/file-coding.c:3390:
warning: pointer targets in initialization differ in signedness
+/usr/local/src/xemacs-21.5-2006-05-23-mule/src/file-coding.c:3391:
warning: pointer targets in initialization differ in signedness
Thank you in advance for fixing this.
-Vin
--
Whoever you are, no matter how lonely,
the world offers itself to your imagination,
calls to you like the wild geese, harsh and exciting--
over and over announcing your place
in the family of things. Mary Oliver