[#8815] Segfault in libc strlen, via rb_str_new2 — "Sean E. Russell" <ser@...>

Howdy,

12 messages 2006/09/09
[#8817] Re: Segfault in libc strlen, via rb_str_new2 — Eric Hodel <drbrain@...7.net> 2006/09/09

On Sep 8, 2006, at 10:10 PM, Sean E. Russell wrote:

[ ruby-Bugs-5822 ] Ruby's 'etc' module cannot handle the UID of OS X 'nobody' properly

From: <noreply@...>
Date: 2006-09-20 18:13:06 UTC
List: ruby-core #8897
Bugs item #5822, was opened at 2006-09-20 11:13
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=1698&aid=5822&group_id=426

Category: Core
Group: 1.8.5
Status: Open
Resolution: None
Priority: 3
Submitted By: Erik Hollensbe (erikh)
Assigned to: Nobody (None)
Summary: Ruby's 'etc' module cannot handle the UID of OS X 'nobody' properly

Initial Comment:
Try this (on a mac, to get the full reflection of the problem):
--
#!/usr/bin/env ruby

require 'etc'

p Etc.getpwnam('nobody')
p Etc.getpwuid(4294967294)
--

Apparently OS X assigns -1 to nobody in some places, and ruby is hitting one of those places. However, the underlying problem seems to be that Etc can output a value in some of it's calls that it can't accept as a parameter.


----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=1698&aid=5822&group_id=426

In This Thread

Prev Next