aboutsummaryrefslogtreecommitdiffstats
path: root/tools/kernel2minor/patches/120-fix_create_mode.patch
blob: 8fa87078e1f2ab0a4c204ca785202ad4b78d6e62 (plain)
1
2
3
4
5
6
7
8
9
10
11
--- a/kernel2minor.c
+++ b/kernel2minor.c
@@ -622,7 +622,7 @@ int main(int argc, char *argv[]){
     perror("Can't open kernel file");
     exit(-1);
   }
-  r = creat(res_file, 0);
+  r = open(res_file, O_CREAT | O_TRUNC | O_WRONLY, 0644);
   if(r <= 0){
     perror("Can't create result file");
     close(k);