1 /* Modified by: xChaos, 20121011 */
3 #include "cll1-0.6.2.h"
6 extern struct IP
*ips
, *ip
;
8 void write_json_traffic(char *json
)
10 FILE *f
=fopen(json
, "w");
19 and (ip
->traffic
or ip
->direct
or ip
->proxy
or ip
->upload
))
26 " \"%s\":{ \"lms\": %d, \"ip\":\"%s\", \"total\":%Lu, \"down\":%Lu, \
27 \"proxy\":%Lu, \"up\":%Lu, \"min\":%d, \"max\":%d, \"limit\":%d, \
28 \"pktsup\":%Lu, \"pktsdown\":%Lu, \"realquota\":%Lu, \"credit\":%Lu, \"dailyquota\":%ld }",
29 ip
->name
, ip
->lmsid
, ip
->addr
, ip
->traffic
, ip
->direct
, ip
->proxy
,
30 ip
->upload
, ip
->min
, ip
->desired
, ip
->max
, ip
->pktsup
, ip
->pktsdown
,
31 ip
->realquota
, ip
->credit
, (ip
->min
*ip
->keyword
->data_limit
+(ip
->keyword
->fixed_limit
<<20)));
This page took 0.375101 seconds and 5 git commands to generate.