File: preamble.cc

package info (click to toggle)
stealth 1.45-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 716 kB
  • ctags: 175
  • sloc: cpp: 1,612; makefile: 88; sh: 70
file content (22 lines) | stat: -rw-r--r-- 804 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "scanner.ih"

void Scanner::preamble()
{
    d_sshFork.start();          // start the ssh connection
    d_shFork.start();           // start the sh-connection to the localhost

                                // try to echo a sentinel by having
                                // the ssh connection echo it    
    Util::debug() << "Inserting " << d_sentinel << " into " << 
                    d_sorter["SSH"] << endl;

    d_sshFork << "/bin/echo \"" << d_sentinel << "\"" << endl;

    Util::debug() << "Waiting for " << d_sentinel << " from " << 
                                                d_sorter["SSH"] << endl;

    d_testExitValue = false;
    waitForSentinel(d_sshFork);  // continue after reading 

    Util::debug() << d_sorter["SSH"] << " appears to be functioning well\n";
}