stdio patch

Discuss the development of software, tools, libraries and anything else that helps make ps2dev happen.

Moderators: cheriff, Herben

Post Reply
holiday
Posts: 5
Joined: Sun Aug 21, 2005 10:17 am
Location: Minnesota, USA

stdio patch

Post by holiday »

Could somebody implement this patch into stdio.c for me?

Code: Select all

--- stdio.c	Fri Sep 23 23:09:32 2005
+++ stdio-fopen-rbplus-fix.c	Sun Sep 25 08:09:52 2005
@@ -407,7 +407,7 @@
           break;
         case 'w':
           flag = _IOWRT;
-          iomode = (O_WRONLY | O_CREAT);
+          iomode = (O_WRONLY | O_CREAT | O_TRUNC);
           break;
         case 'a':
           flag = _IORW;
@@ -421,7 +421,7 @@
             continue;
           case '+':
             flag |= (_IOREAD | _IOWRT);
-            iomode |= (O_RDWR | O_CREAT | O_TRUNC);
+            iomode |= O_RDWR;
             continue;
           default:
             break;
--
Thanks
Post Reply