]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Prevent double-inclusion of ssh.h in case of -DNO_SECURITY.
authorSimon Tatham <anakin@pobox.com>
Wed, 23 Apr 2014 14:05:31 +0000 (14:05 +0000)
committerSimon Tatham <anakin@pobox.com>
Wed, 23 Apr 2014 14:05:31 +0000 (14:05 +0000)
winshare.c includes ssh.h, but if you defined NO_SECURITY it then
decides to fall back to including the stub noshare.c, which includes
ssh.h again. Fix by moving a block of includes inside the ifdef.

[originally from svn r10184]

windows/winshare.c

index 17bad46d913e548c4355894509b5af271ead0b07..89c1cc32591d57160c11e489ade7880a9433be06 100644 (file)
@@ -5,6 +5,8 @@
 #include <stdio.h>
 #include <assert.h>
 
+#if !defined NO_SECURITY
+
 #define DEFINE_PLUG_METHOD_MACROS
 #include "tree234.h"
 #include "putty.h"
@@ -12,8 +14,6 @@
 #include "proxy.h"
 #include "ssh.h"
 
-#if !defined NO_SECURITY
-
 #include "winsecur.h"
 
 #define CONNSHARE_PIPE_PREFIX "\\\\.\\pipe\\putty-connshare"