mirror of
https://github.com/irssi/irssi.git
synced 2025-02-02 15:08:01 -05:00
always round up the kB value so we won't have 0kB file sizes..
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1468 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
4c42e7d894
commit
c61edaf7c9
@ -67,7 +67,8 @@ static void dcc_closed(GET_DCC_REC *dcc)
|
|||||||
} else {
|
} else {
|
||||||
printformat(dcc->server, NULL, MSGLEVEL_DCC,
|
printformat(dcc->server, NULL, MSGLEVEL_DCC,
|
||||||
IRCTXT_DCC_GET_COMPLETE, dcc->arg,
|
IRCTXT_DCC_GET_COMPLETE, dcc->arg,
|
||||||
dcc->transfd/1024, dcc->nick, (long) secs, kbs);
|
(dcc->transfd+1023)/1024,
|
||||||
|
dcc->nick, (long) secs, kbs);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,8 +59,8 @@ static void dcc_closed(SEND_DCC_REC *dcc)
|
|||||||
} else {
|
} else {
|
||||||
printformat(dcc->server, NULL, MSGLEVEL_DCC,
|
printformat(dcc->server, NULL, MSGLEVEL_DCC,
|
||||||
IRCTXT_DCC_SEND_COMPLETE,
|
IRCTXT_DCC_SEND_COMPLETE,
|
||||||
dcc->arg, dcc->transfd/1024, dcc->nick,
|
dcc->arg, (dcc->transfd+1023)/1024,
|
||||||
(long) secs, kbs);
|
dcc->nick, (long) secs, kbs);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -91,7 +91,7 @@ void dcc_list_print_file(FILE_DCC_REC *dcc)
|
|||||||
printformat(NULL, NULL, MSGLEVEL_DCC,
|
printformat(NULL, NULL, MSGLEVEL_DCC,
|
||||||
IRCTXT_DCC_LIST_LINE_FILE,
|
IRCTXT_DCC_LIST_LINE_FILE,
|
||||||
dcc->nick, dcc_type2str(dcc->type),
|
dcc->nick, dcc_type2str(dcc->type),
|
||||||
dcc->transfd/1024, dcc->size/1024,
|
(dcc->transfd+1023)/1024, (dcc->size+1023)/1024,
|
||||||
dcc->size == 0 ? 0 : (int)((double)dcc->transfd/(double)dcc->size*100.0),
|
dcc->size == 0 ? 0 : (int)((double)dcc->transfd/(double)dcc->size*100.0),
|
||||||
(double) (dcc->transfd-dcc->skipped)/going/1024, dcc->arg);
|
(double) (dcc->transfd-dcc->skipped)/going/1024, dcc->arg);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user