Changeset 1862

Show
Ignore:
Timestamp:
09/10/2007 00:21:48 (15 months ago)
Author:
chris
Message:

Fix crash when notifyscript is called for BackupStart? or BackupFinish?.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • box/trunk/bin/bbackupd/BackupDaemon.cpp

    r1806 r1862  
    22792279        } 
    22802280 
    2281         // Is there a notifation script? 
     2281        // Is there a notification script? 
    22822282        const Configuration &conf(GetConfiguration()); 
    2283         if(!conf.KeyExists("NotifyScript") && 
    2284                 Event != NotifyEvent_BackupStart && 
    2285                 Event != NotifyEvent_BackupFinish) 
     2283        if(!conf.KeyExists("NotifyScript")) 
    22862284        { 
    22872285                // Log, and then return 
    2288                 BOX_ERROR("Not notifying administrator about event " 
    2289                         << sEventNames[Event] << " -- set NotifyScript " 
    2290                         "to do this in future"); 
     2286                if(Event != NotifyEvent_BackupStart && 
     2287                        Event != NotifyEvent_BackupFinish) 
     2288                { 
     2289                        BOX_ERROR("Not notifying administrator about event " 
     2290                                << sEventNames[Event] << " -- set NotifyScript " 
     2291                                "to do this in future"); 
     2292                } 
    22912293                return; 
    22922294        }