[SOLVED]fputchar&fgetchar puzzling me
#1

Dose function "fp(g)utchar" support linux or mac.?
I have no chance to test cuz my pc's platform is WINDOWS,but server's platform is linux(freeBSD).

here's DracoBlue' fcopy code,he mentions that requires for WINDOWS,
pawn Код:
/**
 * Copies a file (Source file won't be deleted!)
 * @param oldname
 *     newname
 * @requires WINDOWS
 */

fcopy(oldname[],newname[]) {
 new File:ohnd,File:nhnd;
 if (!fexist(oldname)) return false;
 ohnd=fopen(oldname,io_read);
 nhnd=fopen(newname,io_write);
 new buf2[1];
 new i;
 for (i=flength(ohnd);i>0;i--) {
  fputchar(nhnd, fgetchar(ohnd, buf2[0],false),false);
 }
 fclose(ohnd);
 fclose(nhnd);
 return true;
}
#pragma unused fcopy
Anyone know about it?thx^^
Reply
#2

Bumb it....
Im waitting for answer here~~~Any help?
Reply
#3

Bump it again...
Where's ur answer?
Reply
#4

Bump it..Anyhelp?
Reply
#5

Well he writted that it was broken on linux.. believe him, or test it yourself (test fputchar and fgetchar)! Why you say you cant test?
Reply
#6

Quote:
Originally Posted by Nubotron
Well he writted that it was broken on linux.. believe him, or test it yourself (test fputchar and fgetchar)! Why you say you cant test?
Thanks,both you im believeing now.
I cannot test cuz of too lazy to doXD
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)