summaryrefslogtreecommitdiff
path: root/anteraja.c
diff options
context:
space:
mode:
authorꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2021-07-17 16:01:30 +0800
committerꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2021-07-17 16:01:30 +0800
commit738aa65629d7b552762cc825829ab5871cd99c4d (patch)
tree1a55f8646b1339b51f7b03f19caa62a92f86b160 /anteraja.c
parent3f8539bd52be8fdfaca4a056373d751799241659 (diff)
Tidy up a bit
Diffstat (limited to 'anteraja.c')
-rw-r--r--anteraja.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/anteraja.c b/anteraja.c
index 89239ab..ffd739a 100644
--- a/anteraja.c
+++ b/anteraja.c
@@ -106,7 +106,7 @@ void anteraja_order(const char *order_number, const char *service, const char *s
sprintf(*url, "%s%s", shipping.base, ORDER_PATH);
enum { SKU, QUANTITY, DESCRIPTION, PRICE, WEIGHT };
char *json = NULL;
- double total_weight = 0;
+ double total_weight = .0;
for (int i = 0; i < nitems; i++) {
size_t length = strlen(ORDER_ITEM) + strlen(items[i][DESCRIPTION]) + ORDER_ITEM_QUANTITY
+ ORDER_ITEM_PRICE + ORDER_ITEM_WEIGHT - strlen("%s") - 3 * strlen("%d")