You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "Donny9 (via GitHub)" <gi...@apache.org> on 2023/09/06 03:37:05 UTC

[GitHub] [nuttx] Donny9 commented on pull request #10475: libs/libc: support unlock version for fread/fwrite/fputc/fgetc/...

Donny9 commented on PR #10475:
URL: https://github.com/apache/nuttx/pull/10475#issuecomment-1707605403

   > During review I just noticed that `fseeko` relies on `lseek` call and not on `_NX_SEEK` and contain code
   > 
   > ```
   > #ifdef CONFIG_DEBUG_FEATURES
   >   /* Verify that we were provided with a stream */
   > 
   >   if (!stream)
   >     {
   >       set_errno(EBADF);
   >       return ERROR;
   >     }
   > #endif
   > ```
   > 
   > instead of
   > 
   > ```
   > #ifdef CONFIG_DEBUG_FEATURES
   >   /* Verify that we were provided with a stream */
   > 
   >   if (!stream)
   >     {
   >       _NX_SETERRNO(EBADF);
   >       return ERROR;
   >     }
   > #endif
   > ```
   > 
   > it would be good if we can fix it
   
   These api with parameter stream handle can't be called in kernel, so don't change these api with _NX_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org