aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/include/ndpi_define.h2
-rw-r--r--src/lib/protocols/oscar.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/include/ndpi_define.h b/src/include/ndpi_define.h
index a181d7e5e..1a135732c 100644
--- a/src/include/ndpi_define.h
+++ b/src/include/ndpi_define.h
@@ -288,7 +288,7 @@
/* define memory callback function */
#define match_first_bytes(payload,st) (memcmp((payload),(st),(sizeof(st)-1))==0)
-#ifdef WIN32
+#if defined(WIN32) && !defined(snprintf)
#define snprintf(buf,len, format,...) _snprintf_s(buf, len,len, format, __VA_ARGS__)
#endif
diff --git a/src/lib/protocols/oscar.c b/src/lib/protocols/oscar.c
index 7222768c3..a43394a8d 100644
--- a/src/lib/protocols/oscar.c
+++ b/src/lib/protocols/oscar.c
@@ -30,7 +30,7 @@
/* Flap channels */
#define SIGNON 0x01
#define DATA 0x02
-#define ERROR 0x03
+#define O_ERROR 0x03
#define SIGNOFF 0x04
#define KEEP_ALIVE 0x05
@@ -101,7 +101,7 @@ static void ndpi_search_oscar_tcp_connect(struct ndpi_detection_module_struct
{
int excluded = 0;
- u_int8_t channel;
+// u_int8_t channel;
u_int16_t family;
u_int16_t type;
u_int16_t flag;
@@ -576,7 +576,7 @@ static void ndpi_search_oscar_tcp_connect(struct ndpi_detection_module_struct
ERROR -> FLAP__ERROR_CHANNEL_0x03
A FLAP error - rare
*/
- if (channel == ERROR)
+ if (channel == O_ERROR)
{
NDPI_LOG(NDPI_PROTOCOL_OSCAR, ndpi_struct, NDPI_LOG_DEBUG, "OSCAR Detected - Error frame \n");
ndpi_int_oscar_add_connection(ndpi_struct, flow);