ソースコードはすでにFedora15,16とUbuntu10、11、12でテストされており、問題はありません。
しかし、Fedora 17では、ファイル書き込み機能が機能しませんでした。
1)
int fd;
if ( 0 < ( fd = open("/home/test/temp/opentest.html", O_CREAT | O_EXCL, 0777))) {
write(fd, "test", strlen("test"));
close(fd);
return "Success";
} else {
return "Error";
}
戻り値:エラー
2)
FILE *pFile;
pFile = fopen("/home/test/temp/opentest.html", "w+");
if (pFile == NULL) {
return "Pointer is NULL";
} else {
fputs("fopen test", pFile);
fclose(pFile);
return "Success";
}
戻り値:「ポインタはNULLです」
ディレクトリの権限でエラーが発生し、777の権限が設定されていると思います。しかし、何も変わりません。
同じコードが通常のCプログラムで機能しました。
なぜfirebreathnpPluginで機能しなかったのですか?
許可について何か違いはありますか?