I'm using SFML 1.6 on Fedora 17.
#include <stdio.h>
#include <errno.h>
#include <error.h>
int main(int argc, char* argv[])
{
FILE *fp = fopen("./simple_vertex.glsl","r");
if (errno)
{
error(1,errno,"File failed to open");
}
return 0;
}
compiles and runs fine when compiled with
g++ -lsfml-system fopen_error_test.cpp -o fopen_error_test && ./fopen_error_test. If I compile with
g++ -lsfml-system -lsfml-window fopen_error_test.cpp -o fopen_error_test && ./fopen_error_test, I get "./fopen_error_test: File failed to open: Resource temporarily unavailable".
Any idea what could be causing this?