summaryrefslogtreecommitdiffstats
path: root/cpukit/rtems/src/partgetbuffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'cpukit/rtems/src/partgetbuffer.c')
-rw-r--r--cpukit/rtems/src/partgetbuffer.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/cpukit/rtems/src/partgetbuffer.c b/cpukit/rtems/src/partgetbuffer.c
index 36910eb7d6..6870d66ca7 100644
--- a/cpukit/rtems/src/partgetbuffer.c
+++ b/cpukit/rtems/src/partgetbuffer.c
@@ -46,6 +46,9 @@ rtems_status_code rtems_partition_get_buffer(
Objects_Locations location;
void *the_buffer;
+ if ( !buffer )
+ return RTEMS_INVALID_ADDRESS;
+
the_partition = _Partition_Get( id, &location );
switch ( location ) {
case OBJECTS_REMOTE: