MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / dfs_win32_read

Function dfs_win32_read

bsp/simulator/drivers/dfs_win32.c:268–281  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

266}
267
268static int dfs_win32_read(struct dfs_file *file, void *buf, size_t len)
269{
270 int fd;
271 int char_read;
272
273 fd = (int)(file->data);
274 char_read = _read(fd, buf, len);
275 if (char_read < 0)
276 return win32_result_to_dfs(GetLastError());
277
278 /* update position */
279 file->pos = _lseek(fd, 0, SEEK_CUR);
280 return char_read;
281}
282
283static int dfs_win32_write(struct dfs_file *file, const void *buf, size_t len)
284{

Callers

nothing calls this directly

Calls 3

win32_result_to_dfsFunction · 0.85
_readFunction · 0.50
_lseekFunction · 0.50

Tested by

no test coverage detected