]> git.scottworley.com Git - tattlekey/blobdiff - client/tattlekey.c
client: Send each report multiple times
[tattlekey] / client / tattlekey.c
index 3a1f7b7b67212de7437b593f1b4f8c1512ad305a..9e7b4b598d9c5d0f5c6c9e4a6e77c9d3845eaa65 100644 (file)
@@ -42,7 +42,11 @@ int main() {
   while (1) {
     char _;
     queue_remove_blocking(&queue, &_);
-    send_report(seq++, 0);
-    signal(2, 100);
+    seq++;
+    for (int i = 0; i < resend_count; i++) {
+      send_report(seq, i);
+      signal(i == 0 ? 2 : 1, 100);
+      sleep_ms(resend_interval_ms);
+    }
   }
 }