mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* ext/etc/etc.c (etc_getpwnam): use PRIsVALUE in format string instead
of %s and RSTRING_PTR * ext/etc/etc.c (etc_getgrnam): ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41558 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
d0690f97de
commit
ff0e82ed9d
2 changed files with 9 additions and 2 deletions
|
@ -1,3 +1,10 @@
|
|||
Sat Jun 22 13:43:00 2013 Charlie Somerville <charliesome@ruby-lang.org>
|
||||
|
||||
* ext/etc/etc.c (etc_getpwnam): use PRIsVALUE in format string instead
|
||||
of %s and RSTRING_PTR
|
||||
|
||||
* ext/etc/etc.c (etc_getgrnam): ditto
|
||||
|
||||
Sat Jun 22 13:07:15 2013 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* bignum.c (CLEAR_LOWBITS): Rewritten without RSHIFTX.
|
||||
|
|
|
@ -183,7 +183,7 @@ etc_getpwnam(VALUE obj, VALUE nam)
|
|||
|
||||
SafeStringValue(nam);
|
||||
pwd = getpwnam(RSTRING_PTR(nam));
|
||||
if (pwd == 0) rb_raise(rb_eArgError, "can't find user for %s", RSTRING_PTR(nam));
|
||||
if (pwd == 0) rb_raise(rb_eArgError, "can't find user for %"PRIsVALUE, nam);
|
||||
return setup_passwd(pwd);
|
||||
#else
|
||||
return Qnil;
|
||||
|
@ -426,7 +426,7 @@ etc_getgrnam(VALUE obj, VALUE nam)
|
|||
|
||||
SafeStringValue(nam);
|
||||
grp = getgrnam(RSTRING_PTR(nam));
|
||||
if (grp == 0) rb_raise(rb_eArgError, "can't find group for %s", RSTRING_PTR(nam));
|
||||
if (grp == 0) rb_raise(rb_eArgError, "can't find group for %"PRIsVALUE, nam);
|
||||
return setup_group(grp);
|
||||
#else
|
||||
return Qnil;
|
||||
|
|
Loading…
Reference in a new issue