#ifndef ED25519_NO_SEED
#ifdef _WIN32
-#include <Windows.h>
-#include <Wincrypt.h>
+#include <windows.h>
+#include <wincrypt.h>
#else
#include <stdio.h>
#endif
return 1;
}
- fread(seed, 1, 32, f);
+ if(fread(seed, 32, 1, f) != 1) {
+ fclose(f);
+ return 1;
+ }
+
fclose(f);
#endif
return 0;
}
-#endif
\ No newline at end of file
+#endif