Skip to content

Commit f4fa821

Browse files
committed
version identifier expanded to provide more info
win32 port says if Visual Studio was used (Win32 port with VS ). MingW compiler version would say "Win32 port" .
1 parent 4d95292 commit f4fa821

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

sshconnect.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -681,9 +681,14 @@ send_client_banner(int connection_out, int minor1)
681681
xasprintf(&client_version_string, "SSH-%d.%d-%.100s\r\n",
682682
PROTOCOL_MAJOR_2, PROTOCOL_MINOR_2, SSH_VERSION);
683683
#else
684+
#ifdef WIN32_VS
685+
xasprintf(&client_version_string, "SSH-%d.%d-%.100sp1 Microsoft Win32 port with VS %s\r\n",
686+
PROTOCOL_MAJOR_2, PROTOCOL_MINOR_2, SSH_VERSION, __DATE__ );
687+
#else
684688
xasprintf(&client_version_string, "SSH-%d.%d-%.100sp1 Microsoft Win32 port %s\r\n",
685689
PROTOCOL_MAJOR_2, PROTOCOL_MINOR_2, SSH_VERSION, __DATE__ );
686690
#endif
691+
#endif
687692
} else {
688693
xasprintf(&client_version_string, "SSH-%d.%d-%.100s\n",
689694
PROTOCOL_MAJOR_1, minor1, SSH_VERSION);

version.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@
55
#ifndef WIN32_FIXME
66
#define SSH_PORTABLE "p1"
77
#else
8+
#ifdef WIN32_VS
9+
#define SSH_PORTABLE "p1 Microsoft Win32 port with VS"
10+
#else
811
#define SSH_PORTABLE "p1 Microsoft Win32 port"
912
#endif
13+
#endif
1014
#define SSH_RELEASE SSH_VERSION SSH_PORTABLE

0 commit comments

Comments
 (0)