summaryrefslogtreecommitdiff
path: root/replay.h
diff options
context:
space:
mode:
authorLuke Bratch <luke@bratch.co.uk>2019-05-11 19:03:57 +0100
committerLuke Bratch <luke@bratch.co.uk>2019-05-11 19:03:57 +0100
commit0559bff00a6be2054194632c3543bf62af1fb56f (patch)
treef007a35d1d7af9a7fa1166831b982c84111baad7 /replay.h
parentc46d01b5afd2da4779efb2700469037eca6122be (diff)
Add the ability to replay messages from a replay log file. (No replay log file writing yet.)
Diffstat (limited to 'replay.h')
-rw-r--r--replay.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/replay.h b/replay.h
new file mode 100644
index 0000000..e0b5822
--- /dev/null
+++ b/replay.h
@@ -0,0 +1,21 @@
+#ifndef REPLAY_H_INCLUDED
+#define REPLAY_H_INCLUDED
+
+#define _XOPEN_SOURCE
+#include <stdio.h>
+#include <string.h>
+#include <stdlib.h>
+#include <time.h>
+#include <ctype.h>
+
+#define MAXCHAR 1000
+#define TIMELEN 11 // 32-bit unixtime is up to 10 characters (+1 for null char) // TODO - Make this Year 2038 proof
+#define TIMELENF 11 // [HH:MM:SS] = 10 characters + 1 for null char
+
+int relaylines(int seconds);
+
+int readrelayline(int seconds, int linenum, char *str);
+
+int writerelayline(char *str);
+
+#endif