diff options
Diffstat (limited to 'adept/adept/dpkgpm.cpp')
-rw-r--r-- | adept/adept/dpkgpm.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/adept/adept/dpkgpm.cpp b/adept/adept/dpkgpm.cpp index 00eb36d..025d50f 100644 --- a/adept/adept/dpkgpm.cpp +++ b/adept/adept/dpkgpm.cpp @@ -112,9 +112,9 @@ bool DPkgPM::forkDpkg (char *const argv[]) close( m_dpkgPipe[1] ); fcntl( m_dpkgPipe[0], F_SETFL, O_NONBLOCK ); - int tqStatus = 0; + int Status = 0; int ret = 0; - while ((ret = waitpid (Child, &tqStatus, WNOHANG)) != Child) { + while ((ret = waitpid (Child, &Status, WNOHANG)) != Child) { if (errno == EINTR || ret == 0) { dpkgMonitor (); usleep (200000); // 0.2 second hang @@ -131,14 +131,14 @@ bool DPkgPM::forkDpkg (char *const argv[]) signal(SIGINT,old_SIGINT); // Check for an error code. - if (WIFEXITED(tqStatus) == 0 || WEXITSTATUS(tqStatus) != 0) + if (WIFEXITED(Status) == 0 || WEXITSTATUS(Status) != 0) { runScripts ("DPkg::Post-Invoke", false); - if (WIFSIGNALED(tqStatus) != 0 && WTERMSIG(tqStatus) == SIGSEGV) + if (WIFSIGNALED(Status) != 0 && WTERMSIG(Status) == SIGSEGV) return _error->Error("Sub-process %s received a segmentation fault.", argv [0]); - if (WIFEXITED(tqStatus) != 0) - return _error->Error("Sub-process %s returned an error code (%u)", argv[0], WEXITSTATUS(tqStatus)); + if (WIFEXITED(Status) != 0) + return _error->Error("Sub-process %s returned an error code (%u)", argv[0], WEXITSTATUS(Status)); return _error->Error("Sub-process %s exited unexpectedly", argv[0]); } @@ -313,7 +313,7 @@ void DPkgPM::dpkgMonitor () r = ""; else r = string( r, colon + 2, string::npos ); - updatetqStatus( p, e, r ); + updateStatus( p, e, r ); } b = string( b, nl + 1, string::npos ); @@ -323,7 +323,7 @@ void DPkgPM::dpkgMonitor () } } -void DPkgPM::updatetqStatus( std::string pkg, std::string ev, std::string r ) +void DPkgPM::updateStatus( std::string pkg, std::string ev, std::string r ) { //std::cerr << "DPkgPM::updateStatus " << pkg << " " << ev << " " << r // << std::endl; @@ -336,7 +336,7 @@ void DPkgPM::updatetqStatus( std::string pkg, std::string ev, std::string r ) return; } - OpAndtqStatus os = std::make_pair( m_currentOp, ev ); + OpAndStatus os = std::make_pair( m_currentOp, ev ); if ( m_seenOps[ std::make_pair( os, pkg ) ] == 0 ) { m_seenOpCount++; m_seenOps[ std::make_pair( os, pkg ) ] = 1; |