weiteres Problem mit socket++

rocky10 rocky_10 at gmx.de
Mit Apr 19 05:41:10 CEST 2000


hi,

ich bin's schon wieder (*an eigener Unfaehigkeit verzweifel)

ich habe die lieb-datei nach /usr/lib und /lib/ kopiert, und
anschliessend mit
..-L /usr/lib
compiliert. Trotzdem rasseln die Fehlermeldungen ueber den Bildschirm


cu, rocky10
-------------- nächster Teil --------------
[root at online 2]# c++ -L /usr/lib -o tsinread tsinread.cc
In file included from sockinet.h:14,
                 from tsinread.cc:1:
/usr/include/sockstream.h:58: warning: `SO_SNDLOWAT' redefined
/usr/include/asm/socket.h:27: warning: this is the location of the previous definition
/usr/include/sockstream.h:59: warning: `SO_RCVLOWAT' redefined
/usr/include/asm/socket.h:26: warning: this is the location of the previous definition
/usr/include/sockstream.h:60: warning: `SO_SNDTIMEO' redefined
/usr/include/asm/socket.h:29: warning: this is the location of the previous definition
/usr/include/sockstream.h:61: warning: `SO_RCVTIMEO' redefined
/usr/include/asm/socket.h:28: warning: this is the location of the previous definition
tsinread.cc: In function `int main()':
tsinread.cc:5: parse error before `:'
/usr/include/g++-2/streambuf.h: In method `iosockinet::iosockinet(const class iosockinet &)':
/usr/include/g++-2/streambuf.h:128: `ios::ios(const class ios &)' is private
tsinread.cc:10: within this context
/usr/include/g++-2/streambuf.h: In method `iosockstream::iosockstream(const class iosockstream &)':
/usr/include/g++-2/streambuf.h:128: `ios::ios(const class ios &)' is private
tsinread.cc:10: within this context
/usr/include/g++-2/streambuf.h: In method `iostream::iostream(const class iostream &)':
/usr/include/g++-2/streambuf.h:128: `ios::ios(const class ios &)' is private
tsinread.cc:10: within this context
/usr/include/g++-2/streambuf.h: In method `istream::istream(const class istream
&)':
/usr/include/g++-2/streambuf.h:128: `ios::ios(const class ios &)' is private
tsinread.cc:10: within this context
/usr/include/g++-2/streambuf.h: In method `ostream::ostream(const class ostream
&)':
/usr/include/g++-2/streambuf.h:128: `ios::ios(const class ios &)' is private
tsinread.cc:10: within this context

-------------- nächster Teil --------------
#include "sockinet.h"
int main()
{
  sockinetbuf si(sockbuf::sock_stream);
  si.bind():
    
    cout << si.localhost() << ' ' << si.localport() << endl;

si.listen();
iosockinet s = si.accept();

char buf[1024];

 while (s >> buf) {
   cout << buf << ' ';
   s<< ::strlen(buf) << endl;
 }
 cout << endl;

return 0;
}