faubackup2/src/common registration.cpp,1.2,1.3 registration.hpp,1.2,1.3
Erik Merkel <[email protected]> Tue, 07 Jun 2005 11:11:19 +0000
| Newsgroups | gmane.comp.sysutils.backup.faubackup.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/faubackup/faubackup2/src/common
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27583/src/common
Modified Files:
registration.cpp registration.hpp
Log Message:
removed old code
Index: registration.hpp
===================================================================
RCS file: /cvsroot/faubackup/faubackup2/src/common/registration.hpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** registration.hpp 6 Jun 2005 12:32:35 -0000 1.2
--- registration.hpp 7 Jun 2005 11:11:17 -0000 1.3
***************
*** 9,15 ****
{
private:
! pid_t child1, child2, ssh_process;
void kill_process(pid_t pid);
- int counter;
public:
--- 9,14 ----
{
private:
! pid_t ssh_process;
void kill_process(pid_t pid);
public:
***************
*** 18,23 ****
void child_died_normal(pid_t pid);
void child_died_abnormal(pid_t pid);
- void register_child1(pid_t pid);
- void register_child2(pid_t pid);
void register_ssh(pid_t pid);
void killAll();
--- 17,20 ----
Index: registration.cpp
===================================================================
RCS file: /cvsroot/faubackup/faubackup2/src/common/registration.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** registration.cpp 6 Jun 2005 12:32:35 -0000 1.2
--- registration.cpp 7 Jun 2005 11:11:17 -0000 1.3
***************
*** 10,14 ****
}
! Registration::Registration():child1(0),child2(0),ssh_process(0), counter(0)
{}
Registration::~Registration()
--- 10,14 ----
}
! Registration::Registration():ssh_process(0)
{}
Registration::~Registration()
***************
*** 16,34 ****
void Registration::child_died_normal(pid_t pid)
{
! // output.information("child died! " + int2string(pid), NORMAL_OUTPUT);
! if(pid == child1) {
! child1 = 0;
! // output.information("child 1 died! ", NORMAL_OUTPUT);
!
! counter--;
! } else if(pid == child2) {
! // output.information("child 2 died! ", NORMAL_OUTPUT);
!
! child2 = 0;
! counter--;
! } else if(pid == ssh_process) {
ssh_process = 0;
! } //else
! // output.critical("unknown child died: " + int2string(pid),0);
}
void Registration::child_died_abnormal(pid_t pid)
--- 16,22 ----
void Registration::child_died_normal(pid_t pid)
{
! if(pid == ssh_process) {
ssh_process = 0;
! }
}
void Registration::child_died_abnormal(pid_t pid)
***************
*** 40,57 ****
}
! void Registration::register_child1(pid_t pid)
! {
! // output.information("child 1 registered " + int2string(pid),
! // NORMAL_OUTPUT);
! child1 = pid;
! counter++;
! }
! void Registration::register_child2(pid_t pid)
! {
! // output.information("child 2 registered " + int2string(pid),
! // NORMAL_OUTPUT);
! child2 = pid;
! counter++;
! }
void Registration::register_ssh(pid_t pid)
{
--- 28,32 ----
}
!
void Registration::register_ssh(pid_t pid)
{
***************
*** 63,70 ****
void Registration::killAll()
{
- if(child1)
- kill_process(child1);
- if(child2)
- kill_process(child2);
if(ssh_process)
kill_process(ssh_process);
--- 38,41 ----
-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games. How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy.
Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20