Module: kamailio
Branch: master
Commit: 97593d20875d26c38511f564fd7071bf79baa56b
URL:
https://github.com/kamailio/kamailio/commit/97593d20875d26c38511f564fd7071b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-06-09T20:02:21+02:00
sipdump: make month in the file name from 1 to 12
- tm_mon is from 0-11
---
Modified: src/modules/sipdump/sipdump_write.c
---
Diff:
https://github.com/kamailio/kamailio/commit/97593d20875d26c38511f564fd7071b…
Patch:
https://github.com/kamailio/kamailio/commit/97593d20875d26c38511f564fd7071b…
---
diff --git a/src/modules/sipdump/sipdump_write.c b/src/modules/sipdump/sipdump_write.c
index 29face97c4..6730d4f602 100644
--- a/src/modules/sipdump/sipdump_write.c
+++ b/src/modules/sipdump/sipdump_write.c
@@ -202,7 +202,7 @@ static int sipdump_rotate_file(void)
n = snprintf(_sipdump_fpath+_sipdump_fpath_prefix.len,
SIPDUMP_FPATH_SIZE-_sipdump_fpath_prefix.len,
"%d-%02d-%02d--%02d-%02d-%02d.data",
- 1900+ti.tm_year, ti.tm_mon, ti.tm_mday,
+ 1900+ti.tm_year, ti.tm_mon+1, ti.tm_mday,
ti.tm_hour, ti.tm_min, ti.tm_sec);
LM_DBG("writing to file: %s (%d)\n", _sipdump_fpath, n);
_sipdump_file = fopen( _sipdump_fpath, "w" );