mirror of
https://github.com/glest/glest-source.git
synced 2025-08-16 21:33:59 +02:00
- copyfile copies files in binary mode now
This commit is contained in:
@@ -1843,8 +1843,8 @@ void copyFileTo(string fromFileName, string toFileName) {
|
|||||||
char *buff_ptr, *find_ptr;
|
char *buff_ptr, *find_ptr;
|
||||||
FILE *fp1, *fp2;
|
FILE *fp1, *fp2;
|
||||||
|
|
||||||
fp1 = fopen(fromFileName.c_str(),"r");
|
fp1 = fopen(fromFileName.c_str(),"rb");
|
||||||
fp2 = fopen(toFileName.c_str(),"w");
|
fp2 = fopen(toFileName.c_str(),"wb");
|
||||||
|
|
||||||
while(fgets(buffer,MAX_LEN_SINGLE_LINE + 2,fp1)) {
|
while(fgets(buffer,MAX_LEN_SINGLE_LINE + 2,fp1)) {
|
||||||
buff_ptr = buffer;
|
buff_ptr = buffer;
|
||||||
|
Reference in New Issue
Block a user