/[rdesktop]/jpeg/rdesktop/trunk/rdpdr.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /jpeg/rdesktop/trunk/rdpdr.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1365 by jsorg71, Thu Jan 4 05:39:39 2007 UTC revision 1372 by jsorg71, Mon Jan 8 04:47:06 2007 UTC
# Line 64  extern DEVICE_FNS disk_fns; Line 64  extern DEVICE_FNS disk_fns;
64  extern DEVICE_FNS scard_fns;  extern DEVICE_FNS scard_fns;
65  #endif  #endif
66  extern FILEINFO g_fileinfo[];  extern FILEINFO g_fileinfo[];
67  extern BOOL g_notify_stamp;  extern RD_BOOL g_notify_stamp;
68    
69  static VCHANNEL *rdpdr_channel;  static VCHANNEL *rdpdr_channel;
70    
# Line 117  convert_to_unix_filename(char *filename) Line 117  convert_to_unix_filename(char *filename)
117          }          }
118  }  }
119    
120  static BOOL  static RD_BOOL
121  rdpdr_handle_ok(int device, int handle)  rdpdr_handle_ok(int device, int handle)
122  {  {
123          switch (g_rdpdr_device[device].device_type)          switch (g_rdpdr_device[device].device_type)
# Line 138  rdpdr_handle_ok(int device, int handle) Line 138  rdpdr_handle_ok(int device, int handle)
138  }  }
139    
140  /* Add a new io request to the table containing pending io requests so it won't block rdesktop */  /* Add a new io request to the table containing pending io requests so it won't block rdesktop */
141  static BOOL  static RD_BOOL
142  add_async_iorequest(uint32 device, uint32 file, uint32 id, uint32 major, uint32 length,  add_async_iorequest(uint32 device, uint32 file, uint32 id, uint32 major, uint32 length,
143                      DEVICE_FNS * fns, uint32 total_timeout, uint32 interval_timeout, uint8 * buffer,                      DEVICE_FNS * fns, uint32 total_timeout, uint32 interval_timeout, uint8 * buffer,
144                      uint32 offset)                      uint32 offset)
# Line 365  rdpdr_process_irp(STREAM s) Line 365  rdpdr_process_irp(STREAM s)
365          uint8 *buffer, *pst_buf;          uint8 *buffer, *pst_buf;
366          struct stream out;          struct stream out;
367          DEVICE_FNS *fns;          DEVICE_FNS *fns;
368          BOOL rw_blocking = True;          RD_BOOL rw_blocking = True;
369          RD_NTSTATUS status = RD_STATUS_INVALID_DEVICE_REQUEST;          RD_NTSTATUS status = RD_STATUS_INVALID_DEVICE_REQUEST;
370    
371          in_uint32_le(s, device);          in_uint32_le(s, device);
# Line 845  rdpdr_process(STREAM s) Line 845  rdpdr_process(STREAM s)
845          unimpl("RDPDR packet type %c%c%c%c\n", magic[0], magic[1], magic[2], magic[3]);          unimpl("RDPDR packet type %c%c%c%c\n", magic[0], magic[1], magic[2], magic[3]);
846  }  }
847    
848  BOOL  RD_BOOL
849  rdpdr_init()  rdpdr_init()
850  {  {
851          if (g_num_devices > 0)          if (g_num_devices > 0)
# Line 861  rdpdr_init() Line 861  rdpdr_init()
861    
862  /* Add file descriptors of pending io request to select() */  /* Add file descriptors of pending io request to select() */
863  void  void
864  rdpdr_add_fds(int *n, fd_set * rfds, fd_set * wfds, struct timeval *tv, BOOL * timeout)  rdpdr_add_fds(int *n, fd_set * rfds, fd_set * wfds, struct timeval *tv, RD_BOOL * timeout)
865  {  {
866          uint32 select_timeout = 0;      /* Timeout value to be used for select() (in millisecons). */          uint32 select_timeout = 0;      /* Timeout value to be used for select() (in millisecons). */
867          struct async_iorequest *iorq;          struct async_iorequest *iorq;
# Line 958  rdpdr_remove_iorequest(struct async_iore Line 958  rdpdr_remove_iorequest(struct async_iore
958    
959  /* Check if select() returned with one of the rdpdr file descriptors, and complete io if it did */  /* Check if select() returned with one of the rdpdr file descriptors, and complete io if it did */
960  static void  static void
961  _rdpdr_check_fds(fd_set * rfds, fd_set * wfds, BOOL timed_out)  _rdpdr_check_fds(fd_set * rfds, fd_set * wfds, RD_BOOL timed_out)
962  {  {
963          RD_NTSTATUS status;          RD_NTSTATUS status;
964          uint32 result = 0;          uint32 result = 0;
# Line 1179  _rdpdr_check_fds(fd_set * rfds, fd_set * Line 1179  _rdpdr_check_fds(fd_set * rfds, fd_set *
1179  }  }
1180    
1181  void  void
1182  rdpdr_check_fds(fd_set * rfds, fd_set * wfds, BOOL timed_out)  rdpdr_check_fds(fd_set * rfds, fd_set * wfds, RD_BOOL timed_out)
1183  {  {
1184          fd_set dummy;          fd_set dummy;
1185    
# Line 1197  rdpdr_check_fds(fd_set * rfds, fd_set * Line 1197  rdpdr_check_fds(fd_set * rfds, fd_set *
1197    
1198    
1199  /* Abort a pending io request for a given handle and major */  /* Abort a pending io request for a given handle and major */
1200  BOOL  RD_BOOL
1201  rdpdr_abort_io(uint32 fd, uint32 major, RD_NTSTATUS status)  rdpdr_abort_io(uint32 fd, uint32 major, RD_NTSTATUS status)
1202  {  {
1203          uint32 result;          uint32 result;

Legend:
Removed from v.1365  
changed lines
  Added in v.1372

  ViewVC Help
Powered by ViewVC 1.1.26