* this function is a POSIX compliant version, which will reset directory * stream. * * @param d the directory stream. */
| 1118 | * @param d the directory stream. |
| 1119 | */ |
| 1120 | void rewinddir(DIR *d) |
| 1121 | { |
| 1122 | if (d && d->fd > 0) |
| 1123 | { |
| 1124 | /* seek to the beginning of directory */ |
| 1125 | if (dfs_file_lseek(fd_get(d->fd), 0, SEEK_SET) >= 0) |
| 1126 | d->num = d->cur = 0; |
| 1127 | } |
| 1128 | } |
| 1129 | RTM_EXPORT(rewinddir); |
| 1130 | |
| 1131 | /** |
nothing calls this directly
no test coverage detected