summaryrefslogtreecommitdiff
path: root/plugins/ConnectionNotify/src/debug.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/ConnectionNotify/src/debug.cpp')
-rw-r--r--plugins/ConnectionNotify/src/debug.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/plugins/ConnectionNotify/src/debug.cpp b/plugins/ConnectionNotify/src/debug.cpp
index d6bff90fe1..0400b3a673 100644
--- a/plugins/ConnectionNotify/src/debug.cpp
+++ b/plugins/ConnectionNotify/src/debug.cpp
@@ -1,7 +1,4 @@
-#include "debug.h"
-
-#define MAX_LENGTH 512
-
+#include "ConnectionNotify.h"
void _OutputDebugString(TCHAR* lpOutputString, ... )
{
@@ -36,7 +33,7 @@ void _OutputDebugString(TCHAR* lpOutputString, ... )
case 's':
{
TCHAR* s = va_arg( argptr, TCHAR * );
- _stprintf(OutMsg,format,s);
+ mir_sntprintf(OutMsg, SIZEOF(OutMsg), format, s);
_tcsncpy(format,OutMsg,_countof(OutMsg));
j = _tcslen(format);
_tcscat(format,_T(" "));
@@ -46,7 +43,7 @@ void _OutputDebugString(TCHAR* lpOutputString, ... )
case 'c':
{
char c = (char) va_arg( argptr, int );
- _stprintf(OutMsg,format,c);
+ mir_sntprintf(OutMsg, SIZEOF(OutMsg), format, c);
_tcsncpy(format,OutMsg,_countof(OutMsg));
j = _tcslen(format);
_tcscat(format,_T(" "));
@@ -56,7 +53,7 @@ void _OutputDebugString(TCHAR* lpOutputString, ... )
case 'd':
{
int d = va_arg( argptr, int );
- _stprintf(OutMsg,format,d);
+ mir_sntprintf(OutMsg, SIZEOF(OutMsg), format, d);
_tcsncpy(format,OutMsg,_countof(OutMsg));
j = _tcslen(format);
_tcscat(format,_T(" "));