Private
Public Access
2
0

api/platform_name: Change return when null platform

Easier to error check against

Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
This commit is contained in:
Thomas Ingleby
2015-01-21 15:39:29 +00:00
parent 53a9a7dce4
commit e8bc227a92
3 changed files with 5 additions and 4 deletions

View File

@@ -303,8 +303,9 @@ mraa_adc_supported_bits()
char*
mraa_get_platform_name()
{
if (plat == NULL)
return "Unknown";
if (plat == NULL) {
return NULL;
}
return (char*) plat->platform_name;
}