Browse files

Fixed ; and warning: win_serialport_impl.c:568: warning: passing arg …

…2 of `GetCommModemStatus' from incompatible pointer type
  • Loading branch information...
1 parent 62922a1 commit dc4430716e75d583939205493e84f0e1c180e9fd Hector G. Parra committed Apr 13, 2010
Showing with 3 additions and 3 deletions.
  1. +1 −1 ext/native/serialport.h
  2. +2 −2 ext/native/win_serialport_impl.c
View
2 ext/native/serialport.h
@@ -21,7 +21,7 @@
#ifndef _RUBY_SERIAL_PORT_H_
#define _RUBY_SERIAL_PORT_H_
-#define RUBY_SERIAL_PORT_VERSION "1.0.1"
+#define RUBY_SERIAL_PORT_VERSION "1.0.3"
#include <ruby.h> /* ruby inclusion */
#ifdef RUBY_1_9 /* ruby io inclusion */
View
4 ext/native/win_serialport_impl.c
@@ -79,7 +79,7 @@ VALUE RB_SERIAL_EXPORT sp_create_impl(class, _port)
{
rb_raise(rb_eArgError, "illegal port number");
}
- sprintf(port, "\\\\.\\COM%d", num_port + 1) /* '0' is actually COM1, etc. */
+ sprintf(port, "\\\\.\\COM%d", num_port + 1); /* '0' is actually COM1, etc. */
break;
case T_STRING:
@@ -562,7 +562,7 @@ void RB_SERIAL_EXPORT get_line_signals_helper_impl(obj, ls)
struct line_signals *ls;
{
HANDLE fh;
- int status;
+ unsigned long status; /* DWORD */
fh = get_handle_helper(obj);
if (GetCommModemStatus(fh, &status) == 0)

0 comments on commit dc44307

Please sign in to comment.