reg: Avoid wvsprintfW() so we can avoid loading user32.dll.
Francois Gouget
fgouget at codeweavers.com
Thu Nov 20 13:49:30 CST 2008
---
Same rationale as for 'regedit /E': this speeds it up a bit and avoids
trying to access X when it may not be available.
programs/reg/Makefile.in | 3 ++-
programs/reg/reg.c | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/programs/reg/Makefile.in b/programs/reg/Makefile.in
index 17e8f81..6fb05f1 100644
--- a/programs/reg/Makefile.in
+++ b/programs/reg/Makefile.in
@@ -5,7 +5,8 @@ SRCDIR = @srcdir@
VPATH = @srcdir@
MODULE = reg.exe
APPMODE = -mconsole -municode
-IMPORTS = advapi32 user32 kernel32
+IMPORTS = advapi32 kernel32
+DELAYIMPORTS = user32
C_SRCS = reg.c
diff --git a/programs/reg/reg.c b/programs/reg/reg.c
index 2f1da6e..34da9f1 100644
--- a/programs/reg/reg.c
+++ b/programs/reg/reg.c
@@ -17,6 +17,7 @@
*/
#include <windows.h>
+#include <wine/unicode.h>
#include "reg.h"
static int reg_printfW(const WCHAR *msg, ...)
@@ -27,7 +28,7 @@ static int reg_printfW(const WCHAR *msg, ...)
WCHAR msg_buffer[8192];
va_start(va_args, msg);
- wvsprintfW(msg_buffer, msg, va_args);
+ vsprintfW(msg_buffer, msg, va_args);
va_end(va_args);
wlen = lstrlenW(msg_buffer);
--
1.5.6.5
More information about the wine-patches
mailing list