1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-14 01:27:35 -05:00

Fix for `slow-startup-printer': use PRINTER_INFO_4 on NT-class systems, which

apparently tries less hard to find printers so won't slow the system down.

Tested on 2000 and 98; in both cases printer enumeration and printing worked
as well as they did in 2003-08-21.

Made a single shared copy of osVersion in winmisc.c so that printing.c can
find it. Made other users (window.c, pageant.c) use this copy.

[originally from svn r3411]
This commit is contained in:
Jacob Nevins
2003-08-21 19:48:45 +00:00
parent 46f26ee483
commit 40dc8b940c
5 changed files with 73 additions and 41 deletions

View File

@ -8,6 +8,8 @@
#include "putty.h"
#include "winstuff.h"
OSVERSIONINFO osVersion;
void platform_get_x11_auth(char *display, int *proto,
unsigned char *data, int *datalen)
{
@ -88,6 +90,13 @@ void SaneEndDialog(HWND hwnd, int ret)
SetWindowLong(hwnd, BOXFLAGS, DF_END);
}
BOOL init_winver(void)
{
ZeroMemory(&osVersion, sizeof(osVersion));
osVersion.dwOSVersionInfoSize = sizeof (OSVERSIONINFO);
return GetVersionEx ( (OSVERSIONINFO *) &osVersion);
}
#ifdef DEBUG
static FILE *debug_fp = NULL;
static HANDLE debug_hdl = INVALID_HANDLE_VALUE;