Fix invalid month in log (missing +1)

parent 54179e2e
......@@ -130,7 +130,7 @@ char *ortp_strdup_printf(const char *fmt,...){
char * ortp_strcat_vprintf(char* dst, const char *fmt, va_list ap){
char *ret;
unsigned long dstlen, retlen;
ret=ortp_strdup_vprintf(fmt, ap);
dstlen = strlen(dst);
retlen = strlen(ret);
......@@ -271,7 +271,7 @@ static void __ortp_logv_out(OrtpLogLevel lev, const char *fmt, va_list args){
}
#endif
#endif
fprintf(__log_file,"%i-%.2i-%.2i %.2i:%.2i:%.2i:%.3i ortp-%s-%s" ENDLINE,1900+lt->tm_year,lt->tm_mon,lt->tm_mday,lt->tm_hour,lt->tm_min,lt->tm_sec,(int)(tp.tv_usec/1000), lname,msg);
fprintf(__log_file,"%i-%.2i-%.2i %.2i:%.2i:%.2i:%.3i ortp-%s-%s" ENDLINE,1900+lt->tm_year,1+lt->tm_mon,lt->tm_mday,lt->tm_hour,lt->tm_min,lt->tm_sec,(int)(tp.tv_usec/1000), lname,msg);
fflush(__log_file);
ortp_free(msg);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment