summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--auth.c11
-rw-r--r--blog.c6
3 files changed, 12 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index d80c8f2..c9fcefa 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
.POSIX:
CFLAGS=-static
-OBJECTS=blog.o post.o
+OBJECTS=blog.o post.o auth.o
all: blog
diff --git a/auth.c b/auth.c
new file mode 100644
index 0000000..fb6db13
--- /dev/null
+++ b/auth.c
@@ -0,0 +1,11 @@
+#define _XOPEN_SOURCE 700
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include "blog.h"
+
+int verify_creds(const char *username, const char *password)
+{
+ printf("verifying '%s'/'%s'\n", username ? username : "", password ? password : "");
+ return 1;
+}
diff --git a/blog.c b/blog.c
index 4c7f3db..b0c6cc2 100644
--- a/blog.c
+++ b/blog.c
@@ -6,12 +6,6 @@
extern char **environ;
-int verify_creds(const char *username, const char *password)
-{
- printf("verifying '%s'/'%s'\n", username ? username : "", password ? password : "");
- return 1;
-}
-
int handle_post(void)
{