diff options
author | Bernd Moessner <berndmoessner80@gmail.com> | 2024-01-07 10:21:40 +0100 |
---|---|---|
committer | Joel Sherrill <joel@rtems.org> | 2024-01-16 10:57:43 -0600 |
commit | a73b52d6a469c330d21e02ea8f82a05edce9fb73 (patch) | |
tree | d7d4155692a0aae6a07ce0357cd9730ae457142a | |
parent | flashdev: Add missing default case (diff) | |
download | rtems-a73b52d6a469c330d21e02ea8f82a05edce9fb73.tar.bz2 |
flashdev.c: return error if both buffers are NULL
Updates #4981
-rw-r--r-- | cpukit/dev/flash/flashdev.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cpukit/dev/flash/flashdev.c b/cpukit/dev/flash/flashdev.c index 8363ac96b1..f39f8dde4d 100644 --- a/cpukit/dev/flash/flashdev.c +++ b/cpukit/dev/flash/flashdev.c @@ -320,7 +320,7 @@ static int rtems_flashdev_read_write( int status; if ( read_buff == NULL && write_buff == NULL ) { - return 0; + rtems_set_errno_and_return_minus_one( EINVAL ); } /* Get flash address */ |