diff options
| author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2006-05-17 09:14:34 +0000 |
|---|---|---|
| committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2006-05-17 09:14:34 +0000 |
| commit | ec6c4298bc94d88f1bbfa000675e99a08914ceed (patch) | |
| tree | 432880071f4b1d3adab18c3c756ddfee74296a43 /dir.c | |
| parent | 5a4060af9f1a1aa1f1c93df75a0bcb93a3fddd32 (diff) | |
| download | ruby-ec6c4298bc94d88f1bbfa000675e99a08914ceed.tar.gz ruby-ec6c4298bc94d88f1bbfa000675e99a08914ceed.tar.xz ruby-ec6c4298bc94d88f1bbfa000675e99a08914ceed.zip | |
* dir.c (sys_warning): should not call a vararg function
rb_sys_warning() indirectly. [ruby-core:07886]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@10162 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'dir.c')
| -rw-r--r-- | dir.c | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -799,9 +799,16 @@ dir_s_rmdir(obj, dir) return INT2FIX(0); } +static void +sys_warning_1(mesg) + const char* mesg; +{ + rb_sys_warning("%s", mesg); +} + #define GLOB_VERBOSE (1 << (sizeof(int) * CHAR_BIT - 1)) #define sys_warning(val) \ - ((flags & GLOB_VERBOSE) && rb_protect((VALUE (*)_((VALUE)))rb_sys_warning, (VALUE)(val), 0)) + ((flags & GLOB_VERBOSE) && rb_protect((VALUE (*)_((VALUE)))sys_warning_1, (VALUE)(val), 0)) /* Return nonzero if S has any special globbing chars in it. */ static int |
