mirror of
https://github.com/3proxy/3proxy.git
synced 2026-11-22 23:59:41 +08:00
Use PRI/SCN modifiers where possible
This commit is contained in:
1 parent
483542b914
commit
0381461495
12 files changed
+21
-22
No files matched your search
@@ -61,7 +61,7 @@ int savecounters(void)
|
||||
unsigned char *tmpbuf,pat_file[]="%s%s.lc";
|
||||
|
||||
|
||||
/* timetoexit !=0 - áóäåì çàâåðøàòüñÿ.*/
|
||||
/* timetoexit !=0 - будем завершаться.*/
|
||||
while (tc != NULL)
|
||||
{
|
||||
tcd = tc;
|
||||
@@ -72,7 +72,7 @@ int savecounters(void)
|
||||
sprintf(tmpbuf,pat_file,ldap_dircount,tcd->ace->users->user);
|
||||
f=fopen(tmpbuf,"w+b");
|
||||
fseek(f,0,SEEK_SET);
|
||||
fprintf(f,"%"PRINTF_INT64_MODIFIER"u %lu %lu\n",tcd->traf64,
|
||||
fprintf(f,"%"PRIu64" %lu %lu\n",tcd->traf64,
|
||||
(unsigned long)tcd->cleared,(unsigned long)tcd->updated);
|
||||
|
||||
fclose(f);
|
||||
@@ -387,7 +387,7 @@ int h_trafgroup(int argc, unsigned char ** argv)
|
||||
|
||||
fseek(f,0,SEEK_SET);
|
||||
fgets(buf, 256, f);
|
||||
sscanf(buf,"%"PRINTF_INT64_MODIFIER"u %lu %lu\n",&rcounter.traf64,
|
||||
sscanf(buf,"%"SCNu64" %lu %lu\n",&rcounter.traf64,
|
||||
&rcounter.cleared, &rcounter.updated);
|
||||
|
||||
|
||||
|
||||
@@ -240,7 +240,7 @@ void mylogfunc(struct clientparam * param, const unsigned char * pz) {
|
||||
}
|
||||
if (DBGLEVEL == 1) {
|
||||
#ifndef NOPSTDINT
|
||||
fprintf(stdout, "Port=%hd; Before: srv=%"PRINTF_INT64_MODIFIER"d, cli=%"PRINTF_INT64_MODIFIER"d; After: srv=%"PRINTF_INT64_MODIFIER"d, cli=%"PRINTF_INT64_MODIFIER"d; nreads=%ld; nwrites=%ld; Rule=%d\n",myhtons(*SAPORT(¶m->sinsr)), statssrv_before, statscli_before, param->statssrv64, param->statscli64,param->nreads,param->nwrites,rule);
|
||||
fprintf(stdout, "Port=%hd; Before: srv=%"PRId64", cli=%"PRId64"; After: srv=%"PRId64", cli=%"PRId64"; nreads=%ld; nwrites=%ld; Rule=%d\n",myhtons(*SAPORT(¶m->sinsr)), statssrv_before, statscli_before, param->statssrv64, param->statscli64,param->nreads,param->nwrites,rule);
|
||||
#else
|
||||
fprintf(stdout, "Port=%hd; Before: srv=%lu, cli=%lu; After: srv=%lu, cli=%lu; nreads=%ld; nwrites=%ld; Rule=%d\n",myhtons(param->sins.sin_port), statssrv_before, statscli_before, param->statssrv, param->statscli,param->nreads,param->nwrites,rule);
|
||||
#endif
|
||||
|
||||
Reference in new issue
Block a user