This is the mail archive of the gcc-prs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: libstdc++/5799: streams reading from fifo


Synopsis: streams reading from fifo

State-Changed-From-To: open->closed
State-Changed-By: rodrigc
State-Changed-When: Sat Mar  2 19:37:55 2002
State-Changed-Why:
    Not a bug in gcc.  For questions about C++, read a good
    C++ book or ask C++ usage questions on the comp.lang.c++.moderated
    Usenet newsgroup.
    
    You probably want to write something like:
    #include <fstream>
    #include <iostream>
     
    int
    main ()
    {
      std::ifstream in ("/tmp/pipe");
      char c;
     
     
      while (in.get(c)) std::cout.put(c);
      return 0;
    }
    
    See 21.3.4 Input of Characters, in Stroustrup's
    book for an example.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=5799


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]