40 |
#include "crypto/md5.h" |
#include "crypto/md5.h" |
41 |
#endif |
#endif |
42 |
|
|
43 |
char title[32] = ""; |
char g_title[32] = ""; |
44 |
char g_username[16]; |
char g_username[16]; |
45 |
char hostname[16]; |
char hostname[16]; |
46 |
char keymapname[16]; |
char keymapname[16]; |
50 |
int g_height = 600; |
int g_height = 600; |
51 |
int tcp_port_rdp = TCP_PORT_RDP; |
int tcp_port_rdp = TCP_PORT_RDP; |
52 |
int g_server_bpp = 8; |
int g_server_bpp = 8; |
53 |
int win_button_size = 0; /* If zero, disable single app mode */ |
int g_win_button_size = 0; /* If zero, disable single app mode */ |
54 |
BOOL g_bitmap_compression = True; |
BOOL g_bitmap_compression = True; |
55 |
BOOL g_sendmotion = True; |
BOOL g_sendmotion = True; |
56 |
BOOL g_orders = True; |
BOOL g_orders = True; |
58 |
BOOL packet_encryption = True; |
BOOL packet_encryption = True; |
59 |
BOOL g_desktop_save = True; |
BOOL g_desktop_save = True; |
60 |
BOOL g_fullscreen = False; |
BOOL g_fullscreen = False; |
61 |
BOOL grab_keyboard = True; |
BOOL g_grab_keyboard = True; |
62 |
BOOL hide_decorations = False; |
BOOL g_hide_decorations = False; |
63 |
BOOL g_use_rdp5 = False; |
BOOL g_use_rdp5 = False; |
64 |
extern BOOL owncolmap; |
extern BOOL g_owncolmap; |
65 |
|
|
66 |
#ifdef RDP2VNC |
#ifdef RDP2VNC |
67 |
extern int rfb_port; |
extern int rfb_port; |
251 |
case 'S': |
case 'S': |
252 |
if (!strcmp(optarg, "standard")) |
if (!strcmp(optarg, "standard")) |
253 |
{ |
{ |
254 |
win_button_size = 18; |
g_win_button_size = 18; |
255 |
break; |
break; |
256 |
} |
} |
257 |
|
|
258 |
win_button_size = strtol(optarg, &p, 10); |
g_win_button_size = strtol(optarg, &p, 10); |
259 |
|
|
260 |
if (*p) |
if (*p) |
261 |
{ |
{ |
330 |
break; |
break; |
331 |
|
|
332 |
case 'C': |
case 'C': |
333 |
owncolmap = True; |
g_owncolmap = True; |
334 |
break; |
break; |
335 |
|
|
336 |
case 'K': |
case 'K': |
337 |
grab_keyboard = False; |
g_grab_keyboard = False; |
338 |
break; |
break; |
339 |
|
|
340 |
case 'T': |
case 'T': |
341 |
STRNCPY(title, optarg, sizeof(title)); |
STRNCPY(g_title, optarg, sizeof(g_title)); |
342 |
break; |
break; |
343 |
|
|
344 |
case 'D': |
case 'D': |
345 |
hide_decorations = True; |
g_hide_decorations = True; |
346 |
break; |
break; |
347 |
|
|
348 |
case 'a': |
case 'a': |
405 |
if (prompt_password && read_password(password, sizeof(password))) |
if (prompt_password && read_password(password, sizeof(password))) |
406 |
flags |= RDP_LOGON_AUTO; |
flags |= RDP_LOGON_AUTO; |
407 |
|
|
408 |
if (title[0] == 0) |
if (g_title[0] == 0) |
409 |
{ |
{ |
410 |
strcpy(title, "rdesktop - "); |
strcpy(g_title, "rdesktop - "); |
411 |
strncat(title, server, sizeof(title) - sizeof("rdesktop - ")); |
strncat(g_title, server, sizeof(g_title) - sizeof("rdesktop - ")); |
412 |
} |
} |
413 |
|
|
414 |
#ifdef RDP2VNC |
#ifdef RDP2VNC |