Fix short block writes on RK06/RK07 devices to write zero filled buffer data. (Oleg Safiullin)

This commit is contained in:
Mark Pizzolato 2013-06-10 05:09:45 -07:00
parent eb921d2ea4
commit 43e5647e96

View file

@ -1144,7 +1144,7 @@ switch (fnc) { /* case on function */
for (i = wc; i < awc; i++) /* fill buf */ for (i = wc; i < awc; i++) /* fill buf */
hkxb[i] = 0; hkxb[i] = 0;
if (wc && !err) { /* write buf */ if (wc && !err) { /* write buf */
fxwrite (hkxb, sizeof (uint16), wc, uptr->fileref); fxwrite (hkxb, sizeof (uint16), awc, uptr->fileref);
err = ferror (uptr->fileref); err = ferror (uptr->fileref);
} }
} /* end if wr */ } /* end if wr */