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

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

revision 25 by matty, Sat Jan 6 03:47:04 2001 UTC revision 28 by matty, Wed Jun 20 13:54:48 2001 UTC
# Line 32  char hostname[16]; Line 32  char hostname[16];
32  int width = 800;  int width = 800;
33  int height = 600;  int height = 600;
34  int keylayout = 0x409;  int keylayout = 0x409;
35    BOOL bitmap_compression = True;
36  BOOL motion = True;  BOOL motion = True;
37  BOOL orders = True;  BOOL orders = True;
38  BOOL licence = True;  BOOL licence = True;
39    BOOL use_encryption = True;
40    BOOL desktop_save = True;
41    BOOL grab_keyboard = True;
42    BOOL fullscreen = False;
43    int private_colormap = False;
44    
45  /* Display usage information */  /* Display usage information */
46  static void  static void
# Line 105  main(int argc, char *argv[]) Line 111  main(int argc, char *argv[])
111                          case 'n':                          case 'n':
112                                  strncpy(hostname, optarg, sizeof(hostname));                                  strncpy(hostname, optarg, sizeof(hostname));
113                                  break;                                  break;
114                            case 'g':
115                          case 'w':                                  {
116                                  width = strtol(optarg, NULL, 10);                                          char *tgem = 0;
117                                  break;                                          width = strtol(optarg, NULL, 10);
118                                            tgem = strchr(optarg, 'x');
119                          case 'h':                                          if ((tgem == 0) || (strlen(tgem) < 2))
120                                  height = strtol(optarg, NULL, 10);                                          {
121                                                    ERROR
122                                                            ("-g: invalid parameter. Syntax example: -g 1024x768\n");
123                                                    exit(1);
124                                            }
125                                            height = strtol(tgem + 1, NULL, 10);
126                                    }
127                                  break;                                  break;
128    
129                          case 'k':                          case 'k':
130                                  keylayout = strtol(optarg, NULL, 16);                                  keylayout = strtol(optarg, NULL, 16);
131                                    /* keylayout = find_keyb_code(optarg); */
132                                    if (keylayout == 0)
133                                            return 0;
134                                  break;                                  break;
135    
136                          case 'm':                          case 'm':
# Line 130  main(int argc, char *argv[]) Line 145  main(int argc, char *argv[])
145                                  licence = False;                                  licence = False;
146                                  break;                                  break;
147    
148                            case 'e':
149                                    use_encryption = False;
150                                    break;
151                            case 'K':
152                                    grab_keyboard = False;
153                                    break;
154                            case 'F':
155                                    fullscreen = True;
156                                    break;
157                            case 'v':
158                                    private_colormap = True;
159                                    break;
160                            case 'h':
161                          case '?':                          case '?':
162                          default:                          default:
163                                  usage(argv[0]);                                  usage(argv[0]);
# Line 166  main(int argc, char *argv[]) Line 194  main(int argc, char *argv[])
194                  }                  }
195          }          }
196    
         if (!rdp_connect(server, flags, domain, password, shell, directory))  
                 return 1;  
   
         STATUS("Connection successful.\n");  
   
197          strcpy(title, "rdesktop - ");          strcpy(title, "rdesktop - ");
198          strncat(title, server, sizeof(title));          strncat(title, server, sizeof(title));
199    
200          if (ui_create_window(title))          if (ui_create_window(title))
201          {          {
202                    if (!rdp_connect(server, flags, domain, password, shell,
203                                     directory))
204                            return 1;
205    
206                    STATUS("Connection successful.\n");
207                  rdp_main_loop();                  rdp_main_loop();
208                  ui_destroy_window();                  ui_destroy_window();
209          }          }

Legend:
Removed from v.25  
changed lines
  Added in v.28

  ViewVC Help
Powered by ViewVC 1.1.26