[En-Nut-Discussion] Opening files for append with size > 16KB failes on Nut/OS 4.6.0
ennut at thezachariasgroup.com
ennut at thezachariasgroup.com
Thu Aug 21 12:46:35 CEST 2008
Ole,
To the best of my knowledge I haven't had any
trouble with the following code.
I'm curious to know if the error remains if you
use it. It may provide a clue where
the problem is.
Thanks!
Zack
MMC_stream = fopen(filename, "a");
if (MMC_stream == 0){
puts("File Open Failed");
return -1;
}
else{
puts(" Opened File OK");
if (fseek (MMC_stream, 0l, SEEK_END) == -1){
puts(" \n\r Seek to End of File Failed");
fclose(MMC_stream);
return -1;
}
else // Seek was OK
{
; //
}
}
At 06:31 AM 8/21/2008, you wrote:
>Hi Harald,
>
> > > When opening a file with is slightly larger than 16 KByte with
> > >
> > > fopen("filename", "a+");
> > I remember that this had been a know bug and I thought it had been fixed
> > some time ago. I'll look into it once again.
>
>Thanks! Is there a workaround? Like opening with r+ and seek to the end
>of file?
>
>Shall I provide you some test files?
>
>Regards,
>
>Ole
>
>--
> _____________________________________________________________
>| |
>| Embedded-IT Hard- und Softwarelösungen |
>| |
>| Ole Reinhardt Tel. / Fax: +49 (0)271 7420433 |
>| Luisenstraße 29 Mobil: +49 (0)177 7420433 |
>| 57076 Siegen eMail: ole.reinhardt at embedded-it.de |
>| Germany Web: http://www.embedded-it.de |
>| UstID / VAT: DE198944716 |
>|_____________________________________________________________|
>
>_______________________________________________
>http://lists.egnite.de/mailman/listinfo/en-nut-discussion
More information about the En-Nut-Discussion
mailing list