diff --git a/btpd/cli_if.c b/btpd/cli_if.c index 23f9f7a..50e9d7a 100644 --- a/btpd/cli_if.c +++ b/btpd/cli_if.c @@ -50,7 +50,8 @@ write_ans(struct io_buffer *iob, struct tlib *tl, enum ipc_tval val) tl->tp == NULL ? tl->content_have : (long long)cm_content(tl->tp)); return; case IPC_TVAL_CSIZE: - buf_print(iob, "i%dei%llde", IPC_TYPE_NUM, tl->content_size); + buf_print(iob, "i%dei%llde", IPC_TYPE_NUM, + (long long)tl->content_size); return; case IPC_TVAL_PCCOUNT: if (tl->tp == NULL) diff --git a/btpd/tlib.c b/btpd/tlib.c index 03c1381..9a2c3af 100644 --- a/btpd/tlib.c +++ b/btpd/tlib.c @@ -164,7 +164,7 @@ save_info(struct tlib *tl) "3:dir%d:%s4:name%d:%s" "14:total downloadi%llde12:total uploadi%llde" "ee", - tl->content_have, tl->content_size, + (long long)tl->content_have, (long long)tl->content_size, (int)strlen(tl->dir), tl->dir, (int)strlen(tl->name), tl->name, tl->tot_down, tl->tot_up); if (iob.error)