[Win32utils-devel] [ win32utils-Bugs-10555 ] wait call in while loop generate "bignum too big to convert into long" error

noreply at rubyforge.org noreply at rubyforge.org
Fri May 4 23:53:18 EDT 2007


Bugs item #10555, was opened at 2007-05-04 01:48
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=411&aid=10555&group_id=85

Category: win32-changejournal
Group: Code
Status: Open
Resolution: None
Priority: 3
Submitted By: Dong Zhang (dzhang)
Assigned to: Park Heesob  (phasis68)
>Summary: wait call in while loop generate "bignum too big to convert into long" error

Initial Comment:
I put the following in a test.rb file. This code comes with the source of Changejournal.

**************************************************
require "win32/changejournal"
include Win32

# Indefinitely wait for a change in 'C:\' and any of its
# subdirectories. Print the file and action affected.

cj = ChangeJournal.new('C:\')

# A ChangeJournal server :)
cj.wait{ |array|
array.each{ |info|
p info.file_name
p info.action
p info.path
}
} while true
**********************************************

the script will run for a while, then quit with the following error

test.rb:10:in `wait': bignum too big to convert into `long long' (RangeError) from test.rb:10

my pc is XP, sp2, with ruby 1.8.5 (2006-12-25 patchlevel 12)

I downloaded the changejournal-0.3.1.so file, renamed it changejournal.so, and drop it in C:\ruby\lib\ruby\site_ruby\1.8\i386-msvcrt\win32.

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

>Comment By: Park Heesob  (phasis68)
Date: 2007-05-05 12:53

Message:


I guess the macro NUM2LL should be NUM2ULL in changejournal.h. 

Regards,
Park Heesob



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

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=411&aid=10555&group_id=85


More information about the win32utils-devel mailing list