aboutsummaryrefslogtreecommitdiff
path: root/ukulele.c
diff options
context:
space:
mode:
authorthe little girl <yui@blekksprut.net>2016-11-11 02:24:43 +0900
committerbie <bie@blekksprut.net>2016-11-11 02:24:43 +0900
commit589634d26bea6cc73aa059f8f6c10c1228e6b1da (patch)
tree8ef56a9ce7a8d6d1c247f6110975d287e23f68db /ukulele.c
parent420d3d932b8529d97a6d8d0556853c34fc029a69 (diff)
downloadukulele-589634d26bea6cc73aa059f8f6c10c1228e6b1da.tar.xz
må kanskje kunne bygges også
Diffstat (limited to 'ukulele.c')
-rw-r--r--ukulele.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ukulele.c b/ukulele.c
index ce12dff..133d30a 100644
--- a/ukulele.c
+++ b/ukulele.c
@@ -141,10 +141,10 @@ int store(char *raw, int len) {
char *id = basename(strdup(raw));
if(chdir(dir))
return problem(404, "Not found");
- size_t len = strlen(loft) + strlen(id) + 256;
- char path[len];
+ size_t siz = strlen(loft) + strlen(id) + 256;
+ char path[siz];
time_t epoch = time(0);
- snprintf(path, len, "%s/%s.%d", loft, id, (int) epoch);
+ snprintf(path, siz, "%s/%s.%d", loft, id, (int) epoch);
FILE *fp = fopen(path, "w");
if(!fp) return redirect("fff", 0);
int pos = 0;