[前][次][番号順一覧][スレッド一覧]

ruby-changes:11888

From: yugui <ko1@a...>
Date: Sat, 23 May 2009 00:22:52 +0900 (JST)
Subject: [ruby-changes:11888] Ruby:r23548 (trunk): * missing/vsnprintf.c (errno): [BUG] fixes a compilation

yugui	2009-05-23 00:22:36 +0900 (Sat, 23 May 2009)

  New Revision: 23548

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=23548

  Log:
    * missing/vsnprintf.c (errno): [BUG] fixes a compilation 
      error on SIZEOF_LONG > SIZEOF_INT.
      (BSD_vfprintf): ditto.

  Modified files:
    trunk/ChangeLog
    trunk/missing/vsnprintf.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 23547)
+++ ChangeLog	(revision 23548)
@@ -1,3 +1,9 @@
+Fri May 22 23:22:53 2009  Yuki Sonoda (Yugui)  <yugui@y...>
+
+	* missing/vsnprintf.c (errno): [BUG] fixes a compilation 
+	  error on SIZEOF_LONG > SIZEOF_INT.
+	  (BSD_vfprintf): ditto.
+
 Fri May 22 23:20:48 2009  Yuki Sonoda (Yugui)  <yugui@y...>
 
 	* spec/default.mspec: follows runruby.rb's move at r23542.
Index: missing/vsnprintf.c
===================================================================
--- missing/vsnprintf.c	(revision 23547)
+++ missing/vsnprintf.c	(revision 23548)
@@ -123,6 +123,10 @@
 #define	NULL	0
 #endif
 
+#if SIZEOF_LONG > SIZEOF_INT
+# include <errno.h>
+#endif
+
 /*
  * NB: to fit things in six character monocase externals, the stdio
  * code uses the prefix `__s' for stdio objects, typically followed
@@ -598,7 +602,7 @@
 #if SIZEOF_LONG > SIZEOF_INT
 	/* abandon if too larger padding */
 #define PAD_L(howmany, with) { \
-	ln = (howmany);
+	ln = (howmany); \
 	if ((long)((int)ln) != ln) { \
 	    errno = ENOMEM; \
 	    goto error; \

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]