Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: JRuby 1.6RC3, JRuby 1.6
-
Component/s: C Extensions
-
Labels:None
-
Number of attachments :
Description
The prototype for rb_time_new doesn't match the definition. The prototype is:
RUBY_DLLSPEC VALUE rb_time_new(long sec, long usec);
https://github.com/jruby/jruby/blob/master/cext/src/include/ruby/ruby.h#L1003
the definition is:
extern "C" VALUE
rb_time_new(time_t sec, long usec)
https://github.com/jruby/jruby/blob/master/cext/src/time.cpp#L23
On OpenBSD i386, the compiler errors out because time_t is int and and not long. Changing the prototype to time_t fixes the issue. Patch attached.
Activity
Jeremy Evans
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Attachment | 0001-Fix-prototype-for-rb_time_new-to-match-definition.patch [ 53954 ] |
Hiro Asari
made changes -
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Assignee | Thomas E Enebo [ enebo ] | Hiro Asari [ asari ] |
| Fix Version/s | JRuby 1.6RC3 [ 17147 ] | |
| Fix Version/s | JRuby 1.6 [ 17062 ] | |
| Resolution | Fixed [ 1 ] |
Charles Oliver Nutter
made changes -
| Status | Resolved [ 5 ] | Closed [ 6 ] |