diff options
author | the little girl <yui@blekksprut.net> | 2016-11-11 02:24:43 +0900 |
---|---|---|
committer | bie <bie@blekksprut.net> | 2016-11-11 02:24:43 +0900 |
commit | 589634d26bea6cc73aa059f8f6c10c1228e6b1da (patch) | |
tree | 8ef56a9ce7a8d6d1c247f6110975d287e23f68db /ukulele.c | |
parent | 420d3d932b8529d97a6d8d0556853c34fc029a69 (diff) | |
download | ukulele-589634d26bea6cc73aa059f8f6c10c1228e6b1da.tar.xz |
må kanskje kunne bygges også
Diffstat (limited to 'ukulele.c')
-rw-r--r-- | ukulele.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -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; |