help! A Write File error??

  • Thread starter Thread starter СÓãÐк£
  • Start date Start date
Ð

СÓãÐк£

Hellow All:
we using Embedded XP in 512M CF card,C driver 320M (protected),D driver
180M;
when we use winsock get file from server ,we write the file to d:.but the
big file (2M over)can not write OK.always only the first part bytes can
write OK ,the last Bytes write 0 in file .
 
Hi,

How exactly you "write the file to d:"? By using "winsock" do you mean you
download the file using Winsock APIs? Then how do you save the file? Can you
show us the code?
You mentioned your c: drive is protected (EWF?). By any chance, could you
"write" operations be cached through c: drive?

Give us more info on your issue and what exactly you are doing in your code
and we may be able to help you.

KM
 
Hi
we use fopen,fwrite,fclose function.
by any chance they don't write right.
I mentioned C:drive is protected.
 
1. This is not enough info to talk about anything. (Not enough even for
guessing)
2. Have you tried this on Windows XP Prof and plugged CF?
3. Do you have any error valued returned.
4. On 180 MB partition it is impossible to create big file. (>2GB) so you
can't have any problems because of big file size.
5. What FS do you use on D: FAT, FAT32, NTFS?

Regards,
Slobodan

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Have an opinion on the effectiveness of Microsoft Embedded newsgroups? Tell
Microsoft!
https://www.windowsembeddedeval.com/community/newsgroups
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
4. He mentioned (2M over) so I guess there should be a plenty of space to write the file. Btw, do you have enough free space to
write the file?
6. Are you able just to copy the big file(s) over network to your d: drive? (any method)
 
4. I know that he mentioned >2MB but since partition size is max 180 MB than
file size must fall between these values.
Also with some languages people have problems controlling singed unsigned
numbers and that fall in 2GB category problem. And FAT32 has 4GB limit on
file size.
All I wanted to say is that 180 MB file is not considered big even for FAT
standards.

6. I agree that would be very good and quick test.

Regards,
Slobodan

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Have an opinion on the effectiveness of Microsoft Embedded newsgroups? Tell
Microsoft!
https://www.windowsembeddedeval.com/community/newsgroups
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

KM said:
4. He mentioned (2M over) so I guess there should be a plenty of space to
write the file. Btw, do you have enough free space to
 
4. Got your point :-). I agree he should be careful with the size.
Although, size_t type is used by fwrite is unsigned integer so he may be good from this point of view.
 
Back
Top