X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=crypto-keygen-standalone.c;fp=crypto-keygen-standalone.c;h=be60446ad680654439352cdf95e8bfa641e4454f;hb=b45ffeee1f5c2d7eaed3ec5af6ff87720b6db97e;hp=1df9d6418931d2aeaba92300729fa78f733fea50;hpb=65d4a5609747aaf729f9ed366ddc08e0d4afcad3;p=xonotic%2Fdarkplaces.git diff --git a/crypto-keygen-standalone.c b/crypto-keygen-standalone.c index 1df9d641..be60446a 100644 --- a/crypto-keygen-standalone.c +++ b/crypto-keygen-standalone.c @@ -97,7 +97,7 @@ void file2buf(const char *fn, char **data, size_t *datasize) *data = NULL; *datasize = 0; size_t n = 0, dn = 0; - if(!strncmp(f, "/dev/fd/", 8)) + if(!strncmp(fn, "/dev/fd/", 8)) f = fdopen(atoi(fn + 8), "wb"); else f = fopen(fn, "rb"); @@ -125,7 +125,7 @@ void file2buf(const char *fn, char **data, size_t *datasize) int buf2file(const char *fn, const char *data, size_t n) { FILE *f; - if(!strncmp(f, "/dev/fd/", 8)) + if(!strncmp(fn, "/dev/fd/", 8)) f = fdopen(atoi(fn + 8), "wb"); else f = fopen(fn, "wb");