Closed asquared closed 14 years ago
In other news, Windows (XP at least) is brain dead. From the looks of things, if you pass a baud rate or other DCB settings which happen to be unsupported by the hardware, SetCommState returns zero but doesn't SetLastError( ) in the process. This in turn causes the Ruby interpreter to crash...
I have a Windows 7 box as well. Will test.
Which ruby?
Ruby 1.9.1p378 from rubyinstaller.org, on XP SP3.
Moved second bug regarding SetLastError() to new issue #21 . Please follow it.
The SetCommState Windows API call allows arbitrary baud rates to be set in addition to the standard enumerated values (see http://msdn.microsoft.com/en-us/library/aa363214%28v=VS.85%29.aspx). Thus, the module should not restrict this use, and the rather lengthy switch statement can be eliminated. I've patched it and pushed the change to a fork...