File: simple.cc

package info (click to toggle)
pstreams 1.0.4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 464 kB
  • sloc: cpp: 2,219; makefile: 207; sh: 18
file content (13 lines) | stat: -rw-r--r-- 196 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
#include <pstreams/pstream.h>

int main() {

  std::string output;
  redi::ipstream one_two_three("echo 123");
  one_two_three >> output;
  if (output != "123") {
    return 1;
  }

  return 0;
}