[maemo-commits] [maemo-commits] r11289 - in projects/haf/trunk/osso-af-startup: debian services

From: subversion at stage.maemo.org subversion at stage.maemo.org
Date: Wed Apr 25 13:39:51 EEST 2007
Author: schulhof
Date: 2007-04-25 13:39:51 +0300 (Wed, 25 Apr 2007)
New Revision: 11289

Modified:
   projects/haf/trunk/osso-af-startup/debian/changelog
   projects/haf/trunk/osso-af-startup/services/real-af-startup
Log:
  * Used calls to osso-backup-startup.sh as 'if' statement conditions to prevent
    non-zero return values from killing real-af-startup


Modified: projects/haf/trunk/osso-af-startup/debian/changelog
===================================================================
--- projects/haf/trunk/osso-af-startup/debian/changelog	2007-04-25 09:56:28 UTC (rev 11288)
+++ projects/haf/trunk/osso-af-startup/debian/changelog	2007-04-25 10:39:51 UTC (rev 11289)
@@ -1,3 +1,10 @@
+osso-af-startup (1.38-2) unstable; urgency=low
+
+  * Used calls to osso-backup-startup.sh as 'if' statement conditions to prevent
+    non-zero return values from killing real-af-startup
+
+ -- Kimmo Hämäläinen <kimmo.hamalainen at nokia.com>  Wed, 25 Apr 2007 13:35:28 +0300
+
 osso-af-startup (1.38-1) unstable; urgency=low
 
   * Added support for auto.install file check in the first boot.

Modified: projects/haf/trunk/osso-af-startup/services/real-af-startup
===================================================================
--- projects/haf/trunk/osso-af-startup/services/real-af-startup	2007-04-25 09:56:28 UTC (rev 11288)
+++ projects/haf/trunk/osso-af-startup/services/real-af-startup	2007-04-25 10:39:51 UTC (rev 11289)
@@ -108,12 +108,16 @@
 
     # Give Backup a chance to restore settings automatically
     if [ -x $AF_INIT_DIR/osso-backup-startup.sh ]; then
-      $AF_INIT_DIR/osso-backup-startup.sh check
-      if [ "x$?" = "x2" ]; then
+      if ! $AF_INIT_DIR/osso-backup-startup.sh check; then
         wizback_method set_progress_visible false
         wizback_method set_descriptions_visible false
 
-        $AF_INIT_DIR/osso-backup-startup.sh
+        # Need to wrap osso-backup-startup.sh into an 'if',
+        # otherwise this script will die when backup exits
+        # non-zero (such as on user cancel)
+        if $AF_INIT_DIR/osso-backup-startup.sh; then
+          echo -n ''
+        fi
 
         wizback_method set_progress_visible true
         wizback_method set_descriptions_visible true


More information about the maemo-commits mailing list