summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2008-12-18 13:15:32 +0000
committerBenny Prijono <bennylp@teluu.com>2008-12-18 13:15:32 +0000
commitcf4c32134b582349fdec64af9df37484728f225c (patch)
treee0b7cac0f89a6fba6f11836a7f0a9cb85d2b55d4
parent30d11975f4123b0dfd06b1ba6d36b8e0bbe09a51 (diff)
Ticket 685: Crash or assertion on debug mode when processing large SIP packet
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2381 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r--pjlib/include/pj/config_site_sample.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/pjlib/include/pj/config_site_sample.h b/pjlib/include/pj/config_site_sample.h
index 30c0e37a..223a1da6 100644
--- a/pjlib/include/pj/config_site_sample.h
+++ b/pjlib/include/pj/config_site_sample.h
@@ -73,6 +73,13 @@
# define PJSIP_MAX_PKT_LEN 2000
+ /* This is important for Symbian. Symbian lacks vsnprintf(), so
+ * if the log buffer is not long enough it's possible that
+ * large incoming packet will corrupt memory when the log tries
+ * to log the packet.
+ */
+# define PJ_LOG_MAX_SIZE (PJSIP_MAX_PKT_LEN+500)
+
/* Since we don't have threads, log buffer can use static buffer */
# define PJ_LOG_USE_STACK_BUFFER 0