Never return null from imv_navigator_selection
This fixes a crash where a null pointer would be used to set an environment variable. Fixes #123
This commit is contained in:
parent
cfafe6d963
commit
a65b30b5da
|
@ -121,7 +121,7 @@ int imv_navigator_add(struct imv_navigator *nav, const char *path,
|
|||
const char *imv_navigator_selection(struct imv_navigator *nav)
|
||||
{
|
||||
if(nav->num_paths == 0) {
|
||||
return NULL;
|
||||
return "";
|
||||
}
|
||||
return nav->paths[nav->cur_path];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue