/[rdesktop]/sourceforge.net/trunk/rdesktop/printer.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 /sourceforge.net/trunk/rdesktop/printer.c

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

revision 603 by stargo, Sat Feb 7 18:47:06 2004 UTC revision 666 by astrand, Sat Apr 17 07:28:30 2004 UTC
# Line 2  Line 2 
2    
3  extern RDPDR_DEVICE g_rdpdr_device[];  extern RDPDR_DEVICE g_rdpdr_device[];
4    
5  PRINTER *  static PRINTER *
6  get_printer_data(HANDLE handle)  get_printer_data(HANDLE handle)
7  {  {
8          int index;          int index;
# Line 16  get_printer_data(HANDLE handle) Line 16  get_printer_data(HANDLE handle)
16  }  }
17    
18  int  int
19  printer_enum_devices(uint32 *id, char *optarg)  printer_enum_devices(uint32 * id, char *optarg)
20  {  {
21          PRINTER *pprinter_data;          PRINTER *pprinter_data;
22    
# Line 109  printer_create(uint32 device_id, uint32 Line 109  printer_create(uint32 device_id, uint32
109  static NTSTATUS  static NTSTATUS
110  printer_close(HANDLE handle)  printer_close(HANDLE handle)
111  {  {
112          PRINTER *pprinter_data;          int i = get_device_index(handle);
113            if (i >= 0)
114          pprinter_data = get_printer_data(handle);          {
115                    PRINTER *pprinter_data = g_rdpdr_device[i].pdevice_data;
116          g_rdpdr_device[get_device_index(handle)].handle = 0;                  if (pprinter_data)
117                            pclose(pprinter_data->printer_fp);
118          pclose(pprinter_data->printer_fp);                  g_rdpdr_device[i].handle = 0;
119            }
120          return STATUS_SUCCESS;          return STATUS_SUCCESS;
121  }  }
122    

Legend:
Removed from v.603  
changed lines
  Added in v.666

  ViewVC Help
Powered by ViewVC 1.1.26