Changeset 4103

Show
Ignore:
Timestamp:
06/13/09 15:26:12 (9 months ago)
Author:
kris
Message:

Fixed a bug with our last update to the SystemUpdaterTray? notifer. Don't continue on
with the patch check if we couldn't check for updates

Location:
pcbsd
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • pcbsd/trunk-current/SystemUpdaterTray/UpdaterTray.cpp

    r4101 r4103  
    258258  QString Version = getLineFromCommandOutput(command); 
    259259 
    260    // Now traverse the directory, see if we have updates. 
    261   readSysUpdates = new Q3Process( this ); 
    262   readSysUpdates->addArgument( "sh"); 
    263   readSysUpdates->addArgument( "/PCBSD/SystemUpdater/bin/readSysUpdatesUser.sh"); 
    264   readSysUpdates->addArgument( Version ); 
    265   readSysUpdates->addArgument(sysPatchsetTmpFile); 
    266   readSysUpdates->addArgument(username); 
    267260 
    268261  // Check to see if the update download was successful and warn if not 
    269262  if ( sysFetchJob->error() != 0 ) 
    270263  { 
    271        // We couldn't fetch any updates, set the status and update the icon 
    272        programstatus = CHECK_FAILED; 
    273        contextMenuRefresh(); 
    274        displayTooltip(); 
    275   }  
    276  
    277   // Connect the exited signal and start the process 
    278   connect( readSysUpdates, SIGNAL(processExited()), this, SLOT(slotReadSystemUpdates() ) ); 
    279   if ( ! readSysUpdates->start() ) { 
     264     // We couldn't fetch any updates, set the status and update the icon 
     265     programstatus = CHECK_FAILED; 
     266     contextMenuRefresh(); 
     267     displayTooltip(); 
     268  } else { 
     269    // Now traverse the directory, see if we have updates. 
     270    readSysUpdates = new Q3Process( this ); 
     271    readSysUpdates->addArgument( "sh"); 
     272    readSysUpdates->addArgument( "/PCBSD/SystemUpdater/bin/readSysUpdatesUser.sh"); 
     273    readSysUpdates->addArgument( Version ); 
     274    readSysUpdates->addArgument(sysPatchsetTmpFile); 
     275    readSysUpdates->addArgument(username); 
     276 
     277    // Connect the exited signal and start the process 
     278    connect( readSysUpdates, SIGNAL(processExited()), this, SLOT(slotReadSystemUpdates() ) ); 
     279    if ( ! readSysUpdates->start() ) { 
    280280        QMessageBox::information( 0, tr("Error!"), tr("Error running updates2 script! "), QMessageBox::Ok ); 
    281   } 
    282  
    283  
     281    } 
     282  } 
    284283 
    285284} 
  • pcbsd/trunk/SystemUpdaterTray/UpdaterTray.cpp

    r4100 r4103  
    258258  QString Version = getLineFromCommandOutput(command); 
    259259 
    260    // Now traverse the directory, see if we have updates. 
    261   readSysUpdates = new Q3Process( this ); 
    262   readSysUpdates->addArgument( "sh"); 
    263   readSysUpdates->addArgument( "/PCBSD/SystemUpdater/bin/readSysUpdatesUser.sh"); 
    264   readSysUpdates->addArgument( Version ); 
    265   readSysUpdates->addArgument(sysPatchsetTmpFile); 
    266   readSysUpdates->addArgument(username); 
    267260 
    268261  // Check to see if the update download was successful and warn if not 
    269262  if ( sysFetchJob->error() != 0 ) 
    270263  { 
    271        // We couldn't fetch any updates, set the status and update the icon 
    272        programstatus = CHECK_FAILED; 
    273        contextMenuRefresh(); 
    274        displayTooltip(); 
    275   }  
    276  
    277   // Connect the exited signal and start the process 
    278   connect( readSysUpdates, SIGNAL(processExited()), this, SLOT(slotReadSystemUpdates() ) ); 
    279   if ( ! readSysUpdates->start() ) { 
     264     // We couldn't fetch any updates, set the status and update the icon 
     265     programstatus = CHECK_FAILED; 
     266     contextMenuRefresh(); 
     267     displayTooltip(); 
     268  } else { 
     269    // Now traverse the directory, see if we have updates. 
     270    readSysUpdates = new Q3Process( this ); 
     271    readSysUpdates->addArgument( "sh"); 
     272    readSysUpdates->addArgument( "/PCBSD/SystemUpdater/bin/readSysUpdatesUser.sh"); 
     273    readSysUpdates->addArgument( Version ); 
     274    readSysUpdates->addArgument(sysPatchsetTmpFile); 
     275    readSysUpdates->addArgument(username); 
     276 
     277    // Connect the exited signal and start the process 
     278    connect( readSysUpdates, SIGNAL(processExited()), this, SLOT(slotReadSystemUpdates() ) ); 
     279    if ( ! readSysUpdates->start() ) { 
    280280        QMessageBox::information( 0, tr("Error!"), tr("Error running updates2 script! "), QMessageBox::Ok ); 
    281   } 
    282  
    283  
     281    } 
     282  } 
    284283 
    285284}