Quantcast
Channel: Renesas Synergy Platform
Viewing all articles
Browse latest Browse all 23645

Forum Post: RE: FileX appending to a existing file with fx_file_relative_seek

$
0
0
Hello Heinz, When incrementing your own offset you're using strlen(). When writing to the file, you're using sizeof(buffer). The buffer is 20 bytes long but only has 10 bytes of data in it so the the remainder is all 0's. Replace fx_file_write(&g_new_file, buffer, sizeof(buffer)); with fx_file_write(&g_new_file, buffer, strlen(buffer)); Regards

Viewing all articles
Browse latest Browse all 23645

Trending Articles