From a9f6f01029f23662714c4d485665ed09332bb8fd Mon Sep 17 00:00:00 2001 From: skeezix Date: Thu, 5 Mar 2009 19:58:22 -0500 Subject: [PATCH] Fixed bug where would crash during merge override PXML if no unique-id --- deployment/etc/pandora/conf/apps | 4 ++-- lib/pnd_pxml.c | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/deployment/etc/pandora/conf/apps b/deployment/etc/pandora/conf/apps index 11f2cd8..80ab306 100644 --- a/deployment/etc/pandora/conf/apps +++ b/deployment/etc/pandora/conf/apps @@ -3,7 +3,7 @@ # Application configuration [autodiscovery] -searchpath /mnt/sd1/pandora/apps:/mnt/sd2/pandora/apps:/usr/pandora/apps # path to depth-search for PXMLs +searchpath /media:/usr/pandora/apps # path to depth-search for PXMLs # PXMLs may be overridden .. ie: overrides are a subset of PXML, where the values are copied over the full PXML [overrides] @@ -11,5 +11,5 @@ searchpath ~/pxml-overrides # [pnd] defines where to locate the pnd support scripts, so the user may override pnd_run.sh without clobbering built in [pnd] -searchpath /mnt/sd1/pandora/scripts:/mnt/sd2/pandora/scripts:/usr/pandora/scripts +searchpath /media/mmcblk0p1/pandora/scripts:/media/mmcblk1p1/pandora/scripts:/usr/pandora/scripts runscript pnd_run.sh diff --git a/lib/pnd_pxml.c b/lib/pnd_pxml.c index 35b21b3..78c41e7 100644 --- a/lib/pnd_pxml.c +++ b/lib/pnd_pxml.c @@ -211,6 +211,10 @@ signed char pnd_pxml_merge_override ( pnd_pxml_handle h, char *searchpath ) { signed char retval = 0; pnd_pxml_handle mergeh; + if ( ! pnd_pxml_get_unique_id ( h ) ) { + return ( -1 ); // no unique-id present, so can't use it to name potential override files + } + SEARCHPATH_PRE { -- 2.39.5