From fulko@wecan.com Tue Oct 02 14:19:14 2001
Received: from wecan.com ([204.225.223.5])
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15oU8P-0000eo-00
	for <bug-commoncpp@gnu.org>; Tue, 02 Oct 2001 14:19:13 -0400
Received: from UNKNOWN(10.0.0.3), claiming to be "wecan.com"
 via SMTP by curly.wecan.com, id smtpdAAAa08560; Tue Oct  2 14:19:02 2001
From: Fulko Hew <fulko@wecan.com>
To: bug-commoncpp@gnu.org
Subject: CommonC++ coredumps with Linux
X-Mailer: ScoMail 3.0.Ca
MIME-Version: 1.0
Date: Tue, 2 Oct 2001 14:22:56 -0400 (EDT)
Content-Type: multipart/mixed; boundary="MIME-boundary-003megLi=pWqF"; charset=iso-8859-1
Message-ID:  <10110021422.aa15455@wecan.com>
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

--MIME-boundary-003megLi=pWqF
Content-Type: text/plain; charset=iso-8859-1



I started using CommonC++ almost 2 years ago, and everything has been
fine until now.

I recently upgraded a box to RedHat 7.1 (with updates including kernel)

Kernel 2.4.3-12
g++    2.96-85

and so I re-ran my regression tests and I get a core dump.  :-(

I have reduced the problem down to a few lines, and maybe someone can
shed some light.  The only thing you may have a problem with is, it
tries to make a socket connection to localhost:finger,
If you don't have that daemon running pick another port.

When running it on other systems (ie. RedHat 6.2) it works
but with RedHat 7.1 it coredumps with this traceback:

Something having to do with sleeping, and thread safety, and
this new kernel/libc, g++ ?

BTW I tried the latest 1.6.1 also.

-------------------------------------------------------------------------------
Fulko Hew,                           Voice:  905-681-5570
Senior Engineering Designer,         Fax:    905-681-5556
SITA ADS                             Email:  fulko@wecan.com
777 Walkers Line,
Burlington, Ontario, Canada, L7N 2G1

--MIME-boundary-003megLi=pWqF
Content-Type: application/octet-stream; name=Makefile; charset=iso-8859-1
Content-Description: Makefile
Content-Transfer-Encoding: Base64

YWxsOiBibG9iCgpGTEFHUz0tRF9HTlVfU09VUkNFIC1EX1RIUkVBRF9TQUZFIC1EX1JFRU5U
UkFOVAoKYmxvYjogYmxvYi5jcHAgTWFrZWZpbGUKCWcrKyAtcHRocmVhZCAkKEZMQUdTKSAt
SS91c3IvbG9jYWwvaW5jbHVkZS9jYysrIC1nIC1PMiAtV2FsbCBibG9iLmNwcCAtbyBibG9i
IC91c3IvbG9jYWwvbGliL2xpYmNjeHguYSAtbHB0aHJlYWQK

--MIME-boundary-003megLi=pWqF
Content-Type: application/octet-stream; name=blob.cpp; charset=iso-8859-1
Content-Description: blob.cpp
Content-Transfer-Encoding: Base64

I2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDxjYysrL2NvbmZpZy5oPgojaW5jbHVkZSA8
Y2MrKy9tYWNyb3MuaD4KI2luY2x1ZGUgPGNjKysvdGhyZWFkLmg+CiNpbmNsdWRlIDxjYysr
L3NvY2tldC5oPgoKY2xhc3MgTWV0cmljIDogcHVibGljIFRocmVhZCB7CglwdWJsaWM6CQkJ
CQlNZXRyaWMoKTsKCXByb3RlY3RlZDoJdm9pZAkJUnVuKCk7Cgl9OwoKTWV0cmljOjpNZXRy
aWMoKSA6IFRocmVhZCgpCXsgfQp2b2lkIE1ldHJpYzo6UnVuKCkgeyB3aGlsZSAoMSkgeyBz
bGVlcCg1KTsgfSB9CgpjbGFzcyBhZHZlcnRpemUgOiBwdWJsaWM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9saWJjLnNvLjYuLi5kb25lLgpMb2FkZWQg
c3ltYm9scyBmb3IgL2xpYi9pNjg2L2xpYmMuc28uNgpSZWFkaW5nIHN5bWJvbHMgZnJvbSAv
bGliL2xkLWxpbnV4LnNvLjIuLi5kb25lLgpMb2FkZWQgc3ltYm9scyBmb3IgL2xpYi9sZC1s
aW51eC5zby4yCiMwICAweDQwMTYzOGUxIGluIF9fbGliY19uYW5vc2xlZXAgKCkgZnJvbSAv
bGliL2k2ODYvbGliYy5zby42CihnZGIpIGJhY2t0cmFjZQojMCAgMHg0MDE2MzhlMSBpbiBf
X2xpYmNfbmFub3NsZWVwICgpIGZyb20gL2xpYi9pNjg2L2xpYmMuc28uNgojMSAgMHg0MDAz
ODA2ZSBpbiBuYW5vc2xlZXAgKHJlcXVlc3RlZF90aW1lPTB4NDAwMWNhMzQsIHJlbWFpbmlu
Zz0weDApIGF0IHdyYXBzeXNjYWxsLmM6MTA1CiMyICAweDA4MDRmMzI1IGluIGNjeHhfc2xl
ZXAgKHRpbWVvdXQ9NTAwMCkgYXQgZnJpZW5kcy5jcHA6MTY1CiMzICAweDA4MDRhYjNkIGlu
IE1ldHJpYzo6UnVuICh0aGlzPTB4YmZmZmY3MTApIGF0IGJsb2IuY3BwOjEzCiM0ICAweDA4
MDRlYjk5IGluIGV4ZWNIYW5kbGVyICh0aD0weGJmZmZmNzEwKSBhdCB0aHJlYWQuY3BwOjQw
NgojNSAgMHg0MDAzM2JmZCBpbiBwdGhyZWFkX3N0YXJ0X3RocmVhZCAoYXJnPTB4NDAwMWNj
MDApIGF0IG1hbmFnZXIuYzoyNjIKKGdkYilxdWl0Cg==

--MIME-boundary-003megLi=pWqF--


From attila.dani@tecnomen.ie Wed Oct 03 05:11:01 2001
Received: from neptune.tecnomen.ie ([193.120.120.162] helo=apollo.tecnomen.ie)
	by fencepost.gnu.org with esmtp (Exim 3.22 #1 (Debian))
	id 15oi3Q-000469-00
	for <bug-commoncpp@gnu.org>; Wed, 03 Oct 2001 05:11:00 -0400
Received: from dano.tecnomen.ie ([194.42.62.131]) by apollo.tecnomen.ie with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13)
	id 4D0S9W5R; Wed, 3 Oct 2001 10:03:52 +0100
Subject: posix TCPStream, Thread
From: Attila Dani <attila.dani@tecnomen.ie>
To: bug-commoncpp@gnu.org
Content-Type: multipart/mixed; boundary="=-QhkVwhmiWpP/1L9EeEjt"
X-Mailer: Evolution/0.10.99 (Preview Release)
Date: 03 Oct 2001 10:09:51 +0100
Message-Id: <1002100191.4478.1.camel@dano>
Mime-Version: 1.0
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

--=-QhkVwhmiWpP/1L9EeEjt
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Hi,

I tried the posix version of the CommonC++ under
a debian linux system (potato), and it seems I
have found two bugs (or maybe features just I used
it on a wrong way).

1. If I recive a sentence via a TCPStream and send
   back an answer without reading the whole input then
   I lose the rest of it. Is it a correct behavior?
   I modified the tcp.cpp demo file. After you compile,
   run and open a telnet session, it should send back 
   your sentence word by word. It does not, just the first
   word! /I attached the code, try: telnet localhost 18070/

2. Thread class: If a thread finishes its task normaly (
   goes throught Initial, Run, Final) and we still have
   the thread object then the isRunning() method returns
   true. This is not right because the thread has already
   stopped. The isRunning() works by the private _tid
   variable of the Thread class. Maybe the next simple 
   modification would help in the execHandler() function:
   ..
   ..
   th->setCancel(THREAD_CANCEL_DISABLED);
    if(!pthread_detach(th->_tid) && th->_parent)
        th->_parent->Notify(th);
    th->Final();
    // !
    th->_tid = 0; //just setting to 0 the _tid
    // !
    pthread_exit(NULL);
  }

Sorry, if I did not understand something correctly.
Regards,
Attila Dani.





--=-QhkVwhmiWpP/1L9EeEjt
Content-Type: text/x-c++
Content-Disposition: attachment; filename=tcp.cpp
Content-ID: <1002099969.4467.0.camel@dano>
Content-Transfer-Encoding: 7bit

// Copyright (C) 1999-2001 Open Source Telecom Corporation.
//  
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 2 of the License, or
// (at your option) any later version.
// 
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
// 
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software 
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
// 
// As a special exception to the GNU General Public License, permission is 
// granted for additional uses of the text contained in its release 
// of Common C++.
// 
// The exception is that, if you link the Common C++ library with other
// files to produce an executable, this does not by itself cause the
// resulting executable to be covered by the GNU General Public License.
// Your use of that executable is in no way restricted on account of
// linking the Common C++ library code into it.
//
// This exception does not however invalidate any other reasons why
// the executable file might be covered by the GNU General Public License.
//
// This exception applies only to the code released under the 
// name Common C++.  If you copy code from other releases into a copy of
// Common C++, as the General Public License permits, the exception does
// not apply to the code that you add in this way.  To avoid misleading
// anyone as to the status of such modified files, you must delete
// this exception notice from them.
// 
// If you write modifications of your own for Common C++, it is your choice
// whether to permit this exception to apply to your modifications.
// If you do not wish that, delete this exception notice.  

#include <config.h>
#include <macros.h>
#include <thread.h>
#include <socket.h>
#include <iostream>
#include <cstdlib>
#include <string>

using namespace std;


int main(int argc, char *argv[])
{
	try {
		TCPSocket So("localhost", 18070);
		So.isPendingConnection();
		TCPStream Stream(So);
		string input;
		while(Stream.isPending(SOCKET_PENDING_INPUT)) {
			Stream >> input;
			Stream << "I got the word: " << input << endl;
			//Stream.sync();
		}
	}
	catch(Socket *socket)
	{
		tpport_t port;
		InetAddress saddr = (InetAddress)socket->getPeer(&port);
		cerr << "socket error " << saddr << ":" << port << endl; 
		cout << "error number " << socket->getErrorNumber() << endl;		
		if(socket->getErrorNumber() == SOCKET_RESOURCE_FAILURE)
		{
			cerr << "bind failed; no resources" << endl;
			exit(-1);
		}
		if(socket->getErrorNumber() == SOCKET_BINDING_FAILED)
		{
			cerr << "bind failed; port busy" << endl;
			exit(-1);
		}
	}
	cout << "timeout after 30 seconds inactivity, exiting" << endl;
    return 0;
}


--=-QhkVwhmiWpP/1L9EeEjt--



From dyfet@ostel.com Wed Oct 03 07:40:34 2001
Received: from [63.124.177.154] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15okO9-0006UX-00
	for <bug-commoncpp@gnu.org>; Wed, 03 Oct 2001 07:40:33 -0400
Received: from ostel.com (home [172.16.1.254])
	by home.sys (Postfix) with ESMTP
	id 53434311E8; Wed,  3 Oct 2001 07:37:55 -0400 (EDT)
Message-ID: <3BBAF893.2030108@ostel.com>
Date: Wed, 03 Oct 2001 07:37:55 -0400
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.3) Gecko/20010802
X-Accept-Language: en-us
MIME-Version: 1.0
To: Attila Dani <attila.dani@tecnomen.ie>
Cc: bug-commoncpp@gnu.org
Subject: Re: posix TCPStream, Thread
References: <1002100191.4478.1.camel@dano>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

This might be an effect of the stream buffering system, but I will have 
to think more about this.  The second issue is a strange one.  Normally 
if one creates a thread that terminates rather than is joined by being 
deleted, then, in theory it probably should delete itself.  If it 
deletes itself, this issue would not happen since there would be no 
object to test :).  In fact, if it does delete itself in it's Final 
method, then this would cause a segfault...

Attila Dani wrote:

>Hi,
>
>I tried the posix version of the CommonC++ under
>a debian linux system (potato), and it seems I
>have found two bugs (or maybe features just I used
>it on a wrong way).
>
>1. If I recive a sentence via a TCPStream and send
>   back an answer without reading the whole input then
>   I lose the rest of it. Is it a correct behavior?
>   I modified the tcp.cpp demo file. After you compile,
>   run and open a telnet session, it should send back 
>   your sentence word by word. It does not, just the first
>   word! /I attached the code, try: telnet localhost 18070/
>
>2. Thread class: If a thread finishes its task normaly (
>   goes throught Initial, Run, Final) and we still have
>   the thread object then the isRunning() method returns
>   true. This is not right because the thread has already
>   stopped. The isRunning() works by the private _tid
>   variable of the Thread class. Maybe the next simple 
>   modification would help in the execHandler() function:
>   ..
>   ..
>   th->setCancel(THREAD_CANCEL_DISABLED);
>    if(!pthread_detach(th->_tid) && th->_parent)
>        th->_parent->Notify(th);
>    th->Final();
>    // !
>    th->_tid = 0; //just setting to 0 the _tid
>    // !
>    pthread_exit(NULL);
>  }
>
>Sorry, if I did not understand something correctly.
>Regards,
>Attila Dani.
>
>
>
>
>
>------------------------------------------------------------------------
>
>// Copyright (C) 1999-2001 Open Source Telecom Corporation.
>//  
>// This program is free software; you can redistribute it and/or modify
>// it under the terms of the GNU General Public License as published by
>// the Free Software Foundation; either version 2 of the License, or
>// (at your option) any later version.
>// 
>// This program is distributed in the hope that it will be useful,
>// but WITHOUT ANY WARRANTY; without even the implied warranty of
>// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>// GNU General Public License for more details.
>// 
>// You should have received a copy of the GNU General Public License
>// along with this program; if not, write to the Free Software 
>// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
>// 
>// As a special exception to the GNU General Public License, permission is 
>// granted for additional uses of the text contained in its release 
>// of Common C++.
>// 
>// The exception is that, if you link the Common C++ library with other
>// files to produce an executable, this does not by itself cause the
>// resulting executable to be covered by the GNU General Public License.
>// Your use of that executable is in no way restricted on account of
>// linking the Common C++ library code into it.
>//
>// This exception does not however invalidate any other reasons why
>// the executable file might be covered by the GNU General Public License.
>//
>// This exception applies only to the code released under the 
>// name Common C++.  If you copy code from other releases into a copy of
>// Common C++, as the General Public License permits, the exception does
>// not apply to the code that you add in this way.  To avoid misleading
>// anyone as to the status of such modified files, you must delete
>// this exception notice from them.
>// 
>// If you write modifications of your own for Common C++, it is your choice
>// whether to permit this exception to apply to your modifications.
>// If you do not wish that, delete this exception notice.  
>
>#include <config.h>
>#include <macros.h>
>#include <thread.h>
>#include <socket.h>
>#include <iostream>
>#include <cstdlib>
>#include <string>
>
>using namespace std;
>
>
>int main(int argc, char *argv[])
>{
>	try {
>		TCPSocket So("localhost", 18070);
>		So.isPendingConnection();
>		TCPStream Stream(So);
>		string input;
>		while(Stream.isPending(SOCKET_PENDING_INPUT)) {
>			Stream >> input;
>			Stream << "I got the word: " << input << endl;
>			//Stream.sync();
>		}
>	}
>	catch(Socket *socket)
>	{
>		tpport_t port;
>		InetAddress saddr = (InetAddress)socket->getPeer(&port);
>		cerr << "socket error " << saddr << ":" << port << endl; 
>		cout << "error number " << socket->getErrorNumber() << endl;		
>		if(socket->getErrorNumber() == SOCKET_RESOURCE_FAILURE)
>		{
>			cerr << "bind failed; no resources" << endl;
>			exit(-1);
>		}
>		if(socket->getErrorNumber() == SOCKET_BINDING_FAILED)
>		{
>			cerr << "bind failed; port busy" << endl;
>			exit(-1);
>		}
>	}
>	cout << "timeout after 30 seconds inactivity, exiting" << endl;
>    return 0;
>}
>
> tcp.cpp
>
> Content-Type:
>
> text/x-c++
> Content-Encoding:
>
> 7bit
>
>




From DSpell@illumina.com Wed Oct 03 21:15:21 2001
Received: from [209.110.221.39] (helo=illumina4.illumina.com)
	by fencepost.gnu.org with esmtp (Exim 3.22 #1 (Debian))
	id 15ox6f-0008H9-00
	for <bug-commoncpp@gnu.org>; Wed, 03 Oct 2001 21:15:21 -0400
Received: by illumina4.illumina.com with Internet Mail Service (5.5.2653.19)
	id <T9NZDAW5>; Wed, 3 Oct 2001 18:15:19 -0700
Message-ID: <6EDF654BC7BFE648AB2E734727E7078D0278D0@illumina24.illumina.com>
From: "Spell, David" <DSpell@illumina.com>
To: "'bug-commoncpp@gnu.org'" <bug-commoncpp@gnu.org>
Subject: Bug in socket.cpp for Win32, version 1.5.1
Date: Wed, 3 Oct 2001 18:15:18 -0700 
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2653.19)
Content-Type: multipart/mixed;
	boundary="----_=_NextPart_000_01C14C72.080BAC50"
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_000_01C14C72.080BAC50
Content-Type: text/plain;
	charset="iso-8859-1"

Hello,

When I try to compile and run apesock.dsw, I get a console app that GPFs in
tcp.cpp at the line "tcp >>  i."  I have extended the tcp.isPending timeout
value to TIMEOUT_INF, so I can press a key before the server closes the
connection, but otherwise, the server app is unchanged.  I connect to it
using "telnet 127.0.0.1 4096," and then press a key on the telnet-side.

Tracing this down, I found that what happens is that the "use_facet"
function in the STL file, XLOCALE, throws a bad_cast exception because there
is apparently no default locale for tcp.  Below is the actual "_THROW" that
causes a problem.  

	else if (!_Cfacet || !_L._Iscloc())
            	    _THROW(bad_cast, "missing locale facet");

I didn't think I had to set up the locale for tcp (I don't for cout), but I
went ahead and added the following to "TCPStream::TCPStream(bool throwflag)"
in socket.cpp:

	streambuf::imbue(locale("C"));	// Estab locale.
	iostream::imbue(locale("C"));	// Estab locale.

This prevented the exception, but now after I execute "tcp >> i," none of
the remaining tcp-output commands work; I get no output at the telnet-client
side, when 'tcp << "user entered " << i << endl' is executed.

Please tell me if I am doing something wrong, but I'm not seeing it.

Thanks in advance!

Regards,

Dave.

FYI:

Platform:	Win2K SR-2
IDE:		Visual C++ 6



Dave Spell
Staff Software Engineer
Illumina, Inc.
9390 Towne Centre Drive
San Diego, CA 92121
(858) 587-4290 x516

We're moving!
Effective October 1, Illumina's new address will be:

9885 Towne Centre Drive
San Diego, CA  92121-1975
T:  (858) 202-4500 Main


 <<David Spell (E-mail).vcf>> 

------_=_NextPart_000_01C14C72.080BAC50
Content-Type: application/octet-stream;
	name="David Spell (E-mail).vcf"
Content-Disposition: attachment;
	filename="David Spell (E-mail).vcf"

BEGIN:VCARD
VERSION:2.1
N:Spell;David
FN:David Spell (E-mail)
ORG:Illumina, Inc
TITLE:Staff Software Engineer
TEL;WORK;VOICE:858-587-4920
TEL;HOME;VOICE:(858) 449-5886
TEL;CELL;VOICE:(858) 449-5886
TEL;WORK;FAX:(858) 587-4297
ADR;WORK:;;9390 Town Center Drive;San Diego;CA;92121;USA
LABEL;WORK;ENCODING=QUOTED-PRINTABLE:9390 Town Center Drive=0D=0ASan Diego, CA 92121=0D=0AUSA
ADR;HOME:;;5220 Fiore Terrace, #M207;San Diego;CA;92122;United States of America
LABEL;HOME;ENCODING=QUOTED-PRINTABLE:5220 Fiore Terrace, #M207=0D=0ASan Diego, CA 92122=0D=0AUnited States of Ame=
rica
EMAIL;PREF;INTERNET:DSpell@illumina.com
REV:20011002T183433Z
END:VCARD

------_=_NextPart_000_01C14C72.080BAC50--


From elmex@x-paste.de Thu Oct 04 12:02:41 2001
Received: from pd9e34c06.dip.t-dialin.net ([217.227.76.6] helo=x-paste.de)
	by fencepost.gnu.org with esmtp (Exim 3.22 #1 (Debian))
	id 15pAxM-0000Hv-00
	for <bug-commoncpp@gnu.org>; Thu, 04 Oct 2001 12:02:40 -0400
Received: from elmex by x-paste.de with local (Exim 3.22 #1)
	id 15pAxO-0002aP-00
	for bug-commoncpp@gnu.org; Thu, 04 Oct 2001 18:02:42 +0200
Date: Thu, 4 Oct 2001 18:02:42 +0200
From: elmex@x-paste.de
To: bug-commoncpp@gnu.org
Subject: Problem with TCPStream (CommonC++-1.6.1)
Message-ID: <20011004180242.A9925@x-paste.de>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.2.5i
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

Hi,

i have a problem with making a simple tcp-client
for writing a IRC-bot.
Here are the only lines of my code (very short):
---------------------------------------------
    #include <iostream>
    #include <string>
    #include <cc++/socket.h>

    int main() {
	cout << "suibot" << endl;

	TCPStream mystream("localhost",6664);
	mystream << "NICK elmex\r\n";
	mystream.sync();
	while(mystream.isConnected()) {
	    while(mystream.isPending(SOCKET_PENDING_INPUT, 2000)) {
		char buf[2];
		mystream.getline(buf,1);
		cout << "line:" << buf[1] << endl;
	    }
	    cout << "Timeout" << endl;
	}
    }
---------------------------------------------
I tested this programm with NetCat:
Console1:
----------
elmex@x-paste: ~$ nc -l -p 6664
NICK elmex
----------
I typed in Console1:
'Foobar and Stuff'

and console2, with the client started gives:
--------------------------------
suibot
IS CON!
Timeout
Timeout
line:
line:
line:
 ...
--------------------------------

I am wondering. The >> operators do work. but i want
unformatted input. Think of binary data or control-characters?

I am using CommonC++ version 1.6.1
uname -a: Linux x-paste.de 2.4.9 #2 Tue Oct 2 12:26:22 CEST 2001 i586 unknown
I have a AMD K6-2 300mhz 192 MB RAM.

If something is missing, mail me.


cya

-- 
Robin Redeker
www:    http://www.x-paste.de/
e-mail: elmex@x-paste.de


From dyfet@ostel.com Sat Oct 06 09:34:28 2001
Received: from [63.124.177.154] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15prb1-0001Cx-00
	for <bug-commoncpp@gnu.org>; Sat, 06 Oct 2001 09:34:27 -0400
Received: from ostel.com (home [172.16.1.254])
	by home.sys (Postfix) with ESMTP
	id C1CDE32060; Sat,  6 Oct 2001 09:32:14 -0400 (EDT)
Message-ID: <3BBF07DE.9090700@ostel.com>
Date: Sat, 06 Oct 2001 09:32:14 -0400
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.3) Gecko/20010802
X-Accept-Language: en-us
MIME-Version: 1.0
To: elmex@x-paste.de
Cc: bug-commoncpp@gnu.org
Subject: Re: Problem with TCPStream (CommonC++-1.6.1)
References: <20011004180242.A9925@x-paste.de>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

For unformatted data, you can always do a read or write stream method.

elmex@x-paste.de wrote:

>Hi,
>
>i have a problem with making a simple tcp-client
>for writing a IRC-bot.
>Here are the only lines of my code (very short):
>---------------------------------------------
>    #include <iostream>
>    #include <string>
>    #include <cc++/socket.h>
>
>    int main() {
>	cout << "suibot" << endl;
>
>	TCPStream mystream("localhost",6664);
>	mystream << "NICK elmex\r\n";
>	mystream.sync();
>	while(mystream.isConnected()) {
>	    while(mystream.isPending(SOCKET_PENDING_INPUT, 2000)) {
>		char buf[2];
>		mystream.getline(buf,1);
>		cout << "line:" << buf[1] << endl;
>	    }
>	    cout << "Timeout" << endl;
>	}
>    }
>---------------------------------------------
>I tested this programm with NetCat:
>Console1:
>----------
>elmex@x-paste: ~$ nc -l -p 6664
>NICK elmex
>----------
>I typed in Console1:
>'Foobar and Stuff'
>
>and console2, with the client started gives:
>--------------------------------
>suibot
>IS CON!
>Timeout
>Timeout
>line:
>line:
>line:
> ...
>--------------------------------
>
>I am wondering. The >> operators do work. but i want
>unformatted input. Think of binary data or control-characters?
>
>I am using CommonC++ version 1.6.1
>uname -a: Linux x-paste.de 2.4.9 #2 Tue Oct 2 12:26:22 CEST 2001 i586 unknown
>I have a AMD K6-2 300mhz 192 MB RAM.
>
>If something is missing, mail me.
>
>
>cya
>




From dyfet@ostel.com Wed Oct 10 11:14:11 2001
Received: from [63.124.177.154] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15rL3j-0003Vp-00
	for <bug-commoncpp@gnu.org>; Wed, 10 Oct 2001 11:14:11 -0400
Received: by home.sys (Postfix, from userid 501)
	id C0BF3339D0; Wed, 10 Oct 2001 11:12:32 -0400 (EDT)
To: Announced@home.sys, bayonne-devel@lists.sourceforge.net,
	bug-commoncpp@gnu.org, ccAudio@home.sys,
	commoncpp-devel@lists.sourceforge.net
Subject: GNU
Message-Id: <20011010151232.C0BF3339D0@home.sys>
Date: Wed, 10 Oct 2001 11:12:32 -0400 (EDT)
From: dyfet@ostel.com (David Sugar)
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

GNU ccAudio is a stand-alone C++ class library and newly designated GNU
package for manipulating audio data, whether on disk or in memory.  GNU
ccAudio offers the ability to work with audio file formats on disk by
treating audio data as sequenced arrays of audio samples rather than 
as arbitrary octets as some audio file manipulation libraries do.

In addition to being audio content aware, GNU ccAudio allows header 
manipulation for setting things like annotation fields.  GNU ccAudio is 
also endian aware and highly portable to both posix and win32 based 
systems.

GNU ccAudio also offers basic audio signal processing including tone data 
set generation and pluggable codec operations.  In the future we will
provide loadable free software audio codec modules for many common 
audio encoding formats where not patent encumbered.

The latest information on GNU ccAudio may alwyas be found at
http://www.gnu.org/software/ccaudio.  The initial GNU release of ccAudio
is 0.4.1, and current releases of this package may be downloaded from
ftp://www.gnu.org/gnu/ccaudio or any gnu mirror worldwide.

Those interested in further developing GNU ccAudio may join the developers
mailing list by sending a subscribe request to
ccaudio-devel-request@gnu.org or by sending email to me directly,
dyfet@gnu.org.  GNU ccaudio development and cvs access is hosted thru
Savannah (http://savannah.gnu.org).  Those wishing to contribute should
also make use of Savannah.



From dyfet@ostel.com Wed Oct 10 11:14:41 2001
Received: from [63.124.177.154] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15rL4D-0003WK-00
	for <bug-commoncpp@gnu.org>; Wed, 10 Oct 2001 11:14:41 -0400
Received: by home.sys (Postfix, from userid 501)
	id 0BD4A339D0; Wed, 10 Oct 2001 11:13:03 -0400 (EDT)
To: Announced@home.sys, bayonne-devel@lists.sourceforge.net,
	bug-commoncpp@gnu.org, ccRTP@home.sys,
	commoncpp-devel@lists.sourceforge.net
Subject: GNU
Message-Id: <20011010151303.0BD4A339D0@home.sys>
Date: Wed, 10 Oct 2001 11:13:03 -0400 (EDT)
From: dyfet@ostel.com (David Sugar)
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

GNU ccRTP is a high performance threadsafe C++ RTP (Real-Time
Transport Protocol) stack and newly designated GNU package.  ccRTP is
built from and requires GNU Common C++.  GNU ccRTP is a fully general
purpose RTP stack that can be used in building both client and server
applications for audio and visual conferencing over the Internet, for
streaming of realtime data, and for next generation IP based telephony
systems.

In addition to basic transport services, GNU ccRTP has support for RTCP
(RTP Control Protocol).  It fully supports multicast operations and class
of service routing.  We would like to add support for RSVP soon.  GNU
ccRTP also provides protocol abstraction thru templates that allow other
low level transport protocols to be easily integrated, in addition to the
default IPV4 UDP sockets.

GNU ccRTP is multi-source connection capable and can be used to build all
forms of standards compliant Internet real-time conferencing systems.  
GNU ccRTP supports temporal packet queuing and live packet filtering within
the stack.  This allows one to implement mixed mode payload transport and
to implement things like embedded telephony signaling in bearer data (RFC
2833).

GNU ccRTP is high performance and uses packet queue lists to track both 
send and receive data temporally.  Unsent packets that fall behind their 
time mark are removed with notification, as are unprocessed packets in the 
receive queue as they become obsolete.  GNU ccRTP also supports partial 
packet assembly and disassembly as is often needed for constructing video 
streams that often do not fit in a single packet frame.

GNU ccRTP offers a simple mechanism for jitter buffering by delaying
between reception and consumption of arriving data as well as providing
accurate timing for streaming of outbound packets.  Any number of
instances of GNU ccRTP may be created in a single process to allow servers
to be constructed.  Each have a separate service thread to optimize and 
isolate active sessions.

The latest information on GNU ccRTP may always be found at
http://www.gnu.org/software/ccrtp.  The initial GNU release of ccRTP
is 0.6.1, and current releases of this package may be downloaded from
ftp://www.gnu.org/gnu/ccrtp or any gnu mirror worldwide.

Those interested in further developing GNU ccRTP may join the developers
mailing list by sending a subscribe request to
ccrtp-devel-request@gnu.org or by sending email to me directly,
dyfet@gnu.org.  GNU ccrtp development and cvs access is hosted thru
Savannah (http://savannah.gnu.org).  Those wishing to contribute should
also make use of Savannah.



From dyfet@ostel.com Wed Oct 10 11:15:08 2001
Received: from [63.124.177.154] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15rL4d-0003YL-00
	for <bug-commoncpp@gnu.org>; Wed, 10 Oct 2001 11:15:07 -0400
Received: by home.sys (Postfix, from userid 501)
	id 384AF339D4; Wed, 10 Oct 2001 11:13:29 -0400 (EDT)
To: Announced@home.sys, bayonne-devel@lists.sourceforge.net,
	bug-commoncpp@gnu.org, ccScript@home.sys,
	commoncpp-devel@lists.sourceforge.net
Subject: GNU
Message-Id: <20011010151329.384AF339D4@home.sys>
Date: Wed, 10 Oct 2001 11:13:29 -0400 (EDT)
From: dyfet@ostel.com (David Sugar)
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

GNU ccScript is a C++ class framework for creating a virtual machine 
execution system for use with and as a scripting/assembler language for 
state-transition driven realtime systems.  The most common example of this
is as the core of the scripting engine found in GNU Bayonne.

GNU ccScript uses a class hierarchy and one extends the ScriptInterp base 
class to create a new dialect localized for a given applications.  One 
then binds script keywords to method calls in the derived class.  This
aspect of GNU ccScript resembles in C++ the process of how one might
localize tcl.

GNU ccScript is intended for use where step execution is important, and 
where each step is in response to a callback event or a state machine 
transition.  It offers deterministic execution and low overhead so that 
many concurrent instances can be running together.

GNU ccScript can execute text files which form the basis of a script 
language.  However, in addition to offering step machine execution, 
GNU ccScript loads all scripts into an active image at once.  This is for 
performance, as all operations in the script system, to assure 
deterministic execution, are in memory.

GNU ccScript also offers the ability to load new scripts in-mass.  
Existing active sessions operate on the currently loaded scripts, and new
sessions are offered the new script.  When the last active session on an 
old script set completes, the entire script set is flushed from memory.  
This enables one to operate scripted servers like GNU Bayonne without
downtime to rebuild script images in memory.

The latest information on GNU ccScript may always be found at
http://www.gnu.org/software/ccscript.  The initial GNU release of ccScript
is 1.7.0, and current releases of this package may be downloaded from
ftp://www.gnu.org/gnu/ccscript or any gnu mirror worldwide.

Those interested in further developing GNU ccScript may join the 
developers mailing list by sending a subscribe request to
ccscript-devel-request@gnu.org or by sending email to me directly,
dyfet@gnu.org.  GNU ccScript development and cvs access is hosted thru
Savannah (http://savannah.gnu.org).  Those wishing to contribute should
also make use of Savannah.



From lsim@bigpond.net.au Sun Oct 21 07:37:40 2001
Received: from mta03ps.bigpond.com ([144.135.25.135])
	by fencepost.gnu.org with esmtp (Exim 3.22 #1 (Debian))
	id 15vGvD-0006SB-00
	for <bug-commoncpp@gnu.org>; Sun, 21 Oct 2001 07:37:39 -0400
Received: from fred.simhome ([144.135.25.75]) by
          mta03ps.bigpond.com (Netscape Messaging Server 4.15) with SMTP
          id GLK0LG00.3QK for <bug-commoncpp@gnu.org>; Sun, 21 Oct 2001
          21:44:04 +1000 
Received: from CPE-61-9-135-141.vic.bigpond.net.au ([61.9.135.141]) by PSMAM03.mailsvc.email.bigpond.com(MailRouter V2.9k 8392/2367368); 21 Oct 2001 21:44:04
From: Lawrence Sim <lsim@bigpond.net.au>
Date: Sun, 21 Oct 2001 11:45:17 GMT
Message-ID: <20011021.11451700@fred.simhome>
Subject: Posix Socket code complains
To: bug-commoncpp@gnu.org
X-Mailer: Mozilla/3.0 (compatible; StarOffice/5.2;Linux)
X-Priority: 3 (Normal)
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

In posix/socket.h the depreciated method OnAccept is commented out,=20
although in posix/socket.cpp it still tries to catch out the old code.=20
This means that the OnAccept method is called twice and an error message=
=20
is displayed.
By commenting this code out, it all works.

The commented out code is on line 1200.

if (tcp.OnAccept(host, (short) port) !=3D false) {
	clog << "### Wrong OnAccept() signature! Overwrite \n"
		<< "\tbool OnAccept(const InetHostAddress &ia,\n"
		<< "\t              tpport_t port);\n"
		<< "\tThis OnAccept() does not work anymore.\n"
		<< "\t(short changed to tpport_t)" << endl;
}


That's all.



From matthias@austria.ibm.com Tue Oct 23 09:58:43 2001
Received: from ibmvie.ibm.co.at ([194.196.47.250] helo=ibmvie.austria.ibm.com)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15w24o-00089x-00
	for <bug-commoncpp@gnu.org>; Tue, 23 Oct 2001 09:58:42 -0400
Received: from spoc.vienna.at.ibm.com (spoc.vienna.at.ibm.com [9.244.3.4])
	by ibmvie.austria.ibm.com (Postfix) with ESMTP id 771BD306
	for <bug-commoncpp@gnu.org>; Tue, 23 Oct 2001 15:58:35 +0200 (SOZ)
Received: from boticelli.vienna.at.ibm.com (boticelli.vienna.at.ibm.com [9.244.6.208]) by spoc.vienna.at.ibm.com (AIX4.3/UCB 8.8.8/8.7) with ESMTP id PAA34762 for <bug-commoncpp@gnu.org>; Tue, 23 Oct 2001 15:55:31 +0200
Received: by boticelli.vienna.at.ibm.com (Postfix, from userid 1000)
	id C9AD5AEC4; Tue, 23 Oct 2001 15:55:20 +0200 (CEST)
Date: Tue, 23 Oct 2001 15:55:20 +0200
From: Matthias Weiss <matthias.we@gmx.at>
To: bug-commoncpp@gnu.org
Subject: new directory features
Message-ID: <20011023155520.A11125@boticelli.vienna.at.ibm.com>
Reply-To: matthias.we@gmx.at
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="+QahgC5+KEYLbs62"
Content-Disposition: inline
User-Agent: Mutt/1.3.17i
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

--+QahgC5+KEYLbs62
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Hi all,
	I've used code from Paul Davis libpbd and modified it to
suite my needs.
It's a directory scanner that returns a vector of strings that
are the names of the directory entries. One can use shell wild
cards and restrict the result to specified types (regular files,
directories, ... ) as well as further ristrictions ( size, owner,
... ).

I'd love to see the code merged into libcommonc++, maybe in the
Dir class. If you like the code please contact me, I have to
ask Paul to get his OK too.

The attached tarball includes a demo program - simply type make
to build it.

Some critics:
-the current class totaly lacks an error concept
-I doubt that it runs on a Windoze box, I've only tested it with linux.
-it offers no further functionality beyond that of the scanner
-for some reason the C-library doesn't recognise symbolic links
-I didn't spend time thinking about security as suggested in the
 security FAQ (at least I think I read something about it there)

--+QahgC5+KEYLbs62
Content-Type: application/octet-stream
Content-Disposition: attachment; filename="dir.tar.gz"
Content-Transfer-Encoding: base64

H4sIAJg91DsAA+09a1PjuLLz9eRX9LK32MBAeDM7YaAqA2Emd3kVhN2au2crZRwl8cWxc20H
lrPD+avnr9xWS7IlP5IwwLzWPbUkkVqtbqnV6m7J3mPrmvUcl714RlhdW13d3tx8sbq6uvZq
a1X/JNjYxu+vNra38NvG5gbir7/a2HoBq8/JlIJxGFkBwIuhFUUDxwqL8KbVf6Nw0DrvtJsX
7c7p2//e7TpBxx4w+7rmw4ET1PxKJS6qw3/9pSPfV/7Rf/kSlvuw7EOMlUGqaDTrCV7NHo2o
C/7peLY77rIV/nuQkLVT6MutGv9vRaJXKsRifToZhYCNK196vL82MIb4mfqYvP7XNrZevVLr
fxMLEH/j1dp2uf4/B6wsVgBh3x/dBU5/EEF1fwHWcVbgWAoMvzHnzcHhHuHRn/bACWEU+P3A
GgJ+7QWMQej3olsrYDtw54/BtjwIWNcJo8C5GkcMnAgsr7viBzD0u07vjghh4djrsgCiAYOI
BcMQ/B79eHdyCe+YxwLLhbPxlevYcOTYzAsZIEcjXhIOWBeuBCHe5JBzcSG5gEMfKVuR43s7
wBysD+CGBSH+hnXViaS4BH5AVKpWxJkPwB/xhgvI8R24VpS0rVVyByCRs4tWiGgP/BGKNECK
KOSt47pwxWAcst7YXSIaiA2/tdrvTy/b0Dj5AL81zs8bJ+0PO4gdDXysZTdM0HKGI9dB0ihY
YHnRHfJPJI6b5/vvsU3jbeuo1f6AYsBhq33SvLiAw9NzaMBZ47zd2r88apzD2eX52elFswZw
wThjjChMGOYeTRWOZJdFluOGUvQPOLkhsud2YWDdMJxkmzk3yJwFNurQ9PkjKpbre30SFLGT
sdwBpweeHy3BbeCg0kR+dmapfTK7S9Dy7NoSbL/aQo0NQ2jc4IT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546yWN4ym3DAydC656RMv
oKIrP5BzQUiqn3YLLquD/S82MZo6UkJHFzEl/QyKmQyJ0kxxheYerYj4yh+76zR/PYtvQ37p
W84llFBCCSWUUEIJJZRQQgkllFBCCSWUUEIJJZRQQgkllFBCCSWU8H3D/wNW+M09AKAAAA==

--+QahgC5+KEYLbs62--


From t.maekitalo@epgmbh.de Thu Oct 25 04:45:25 2001
Received: from mail.eckpart.de ([217.6.160.186] helo=cserv.eckpart.de)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15wg8i-0004KD-00
	for <bug-commoncpp@gnu.org>; Thu, 25 Oct 2001 04:45:25 -0400
Received: (qmail 31192 invoked from network); 25 Oct 2001 08:45:21 -0000
Received: from at13.eckpart.de (HELO epgmbh.de) (192.168.41.70)
  by cserv.eckpart.de with SMTP; 25 Oct 2001 08:45:21 -0000
Message-ID: <3BD7D121.1060203@epgmbh.de>
Date: Thu, 25 Oct 2001 10:45:21 +0200
From: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <t.maekitalo@epgmbh.de>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:0.9.4) Gecko/20010913
X-Accept-Language: de-at, de, en, en-us
MIME-Version: 1.0
To: bug-commoncpp@gnu.org
Subject: Errors in TCPStream
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

Hi,

I am working on a FTP-class and use CommonC++ as a base. But I 
discovered difficulties catching errors. Here is a example-code:

  TCPStream* socket;
  try
  {
    cout << "connecting" << endl;
    socket = new TCPStream(InetHostAddress("localhost"), 4711);

    cout << "delete" << endl;
    delete socket;
    cout << "OK" << endl;
  }
  catch(Socket* s)
  {
    cerr << "socket error " << s->getErrorNumber() << endl
         << s->getErrorString() << endl;
  }

If there is no server listening I should get a SOCKET_CONNECT_FAILED. 
But the problem is, that you use the this-pointer in socket-class to 
throw the exception. But it isn't valid in the catch-block, because the 
constructor isn't fully executed. It makes no difference when I declare 
my socket on the stack like this:

  try
  {
    cout << "connecting" << endl;
    TCPStream socket(InetHostAddress("localhost"), 4711);
    cout << "OK" << endl;
  }
  catch(Socket* s)
  {
    cerr << "socket error " << s->getErrorNumber() << endl
         << s->getErrorString() << endl;
  }

It is better to create a exception-class and throw that. Maybe you can 
derive from std::exception.

Like this:

class SocketException : public std::exception
{
    sockerror_t errid;
    std::string errstr;
  public:
    SocketException(sockerror_t err, const char* errs)
      : errid(err),
        errstr(errs)
        { }
    virtual const char* what() const
    { return errstr.c_str(); }
    sockerror_t getErrorNumber() const  { return errid; }
    std::string getErrorString() const  { return errstr; }
};

Now this should work:

  try
  {
    cout << "connecting" << endl;
    TCPStream socket(InetHostAddress("localhost"), 4711);
    cout << "OK" << endl;
  }
  catch(SocketException s)
  {
    cerr << "socket error " << s->getErrorNumber() << endl
         << s->getErrorString() << endl;
  }

Or even:

  try
  {
    cout << "connecting" << endl;
    TCPStream socket(InetHostAddress("localhost"), 4711);
    cout << "OK" << endl;
  }
  catch(exception e)
  {
    cerr << "exception occured: " << e.what() << endl;
  }

By the way, is there a mailing-list for CommonC++ users, where I can 
subscribe?

Tommi Mäkitalo



From dyfet@ostel.com Thu Oct 25 07:16:34 2001
Received: from [65.188.113.57] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15wiUz-0006ZT-00
	for <bug-commoncpp@gnu.org>; Thu, 25 Oct 2001 07:16:33 -0400
Received: by home.sys (Postfix, from userid 501)
	id 7645B33B85; Thu, 25 Oct 2001 07:17:01 -0400 (EDT)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id 70F0B33B84; Thu, 25 Oct 2001 07:17:01 -0400 (EDT)
Date: Thu, 25 Oct 2001 07:17:01 -0400 (EDT)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <t.maekitalo@epgmbh.de>
Cc: <bug-commoncpp@gnu.org>
Subject: Re: Errors in TCPStream
In-Reply-To: <3BD7D121.1060203@epgmbh.de>
Message-ID: <Pine.LNX.4.33L2.0110250716130.9044-100000@home>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=X-UNKNOWN
Content-Transfer-Encoding: QUOTED-PRINTABLE
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

The older mailing list is at cplusplus-devel@lists.sourceforge.net.  A
std::exception based exception class hierarchy is actually in development.

David

On Thu, 25 Oct 2001, Tommi [ISO-8859-1] M=E4kitalo wrote:

> Hi,
>
> I am working on a FTP-class and use CommonC++ as a base. But I
> discovered difficulties catching errors. Here is a example-code:
>
>   TCPStream* socket;
>   try
>   {
>     cout << "connecting" << endl;
>     socket =3D new TCPStream(InetHostAddress("localhost"), 4711);
>
>     cout << "delete" << endl;
>     delete socket;
>     cout << "OK" << endl;
>   }
>   catch(Socket* s)
>   {
>     cerr << "socket error " << s->getErrorNumber() << endl
>          << s->getErrorString() << endl;
>   }
>
> If there is no server listening I should get a SOCKET_CONNECT_FAILED.
> But the problem is, that you use the this-pointer in socket-class to
> throw the exception. But it isn't valid in the catch-block, because the
> constructor isn't fully executed. It makes no difference when I declare
> my socket on the stack like this:
>
>   try
>   {
>     cout << "connecting" << endl;
>     TCPStream socket(InetHostAddress("localhost"), 4711);
>     cout << "OK" << endl;
>   }
>   catch(Socket* s)
>   {
>     cerr << "socket error " << s->getErrorNumber() << endl
>          << s->getErrorString() << endl;
>   }
>
> It is better to create a exception-class and throw that. Maybe you can
> derive from std::exception.
>
> Like this:
>
> class SocketException : public std::exception
> {
>     sockerror_t errid;
>     std::string errstr;
>   public:
>     SocketException(sockerror_t err, const char* errs)
>       : errid(err),
>         errstr(errs)
>         { }
>     virtual const char* what() const
>     { return errstr.c_str(); }
>     sockerror_t getErrorNumber() const  { return errid; }
>     std::string getErrorString() const  { return errstr; }
> };
>
> Now this should work:
>
>   try
>   {
>     cout << "connecting" << endl;
>     TCPStream socket(InetHostAddress("localhost"), 4711);
>     cout << "OK" << endl;
>   }
>   catch(SocketException s)
>   {
>     cerr << "socket error " << s->getErrorNumber() << endl
>          << s->getErrorString() << endl;
>   }
>
> Or even:
>
>   try
>   {
>     cout << "connecting" << endl;
>     TCPStream socket(InetHostAddress("localhost"), 4711);
>     cout << "OK" << endl;
>   }
>   catch(exception e)
>   {
>     cerr << "exception occured: " << e.what() << endl;
>   }
>
> By the way, is there a mailing-list for CommonC++ users, where I can
> subscribe?
>
> Tommi M=E4kitalo
>
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>



From t.maekitalo@epgmbh.de Thu Oct 25 09:25:44 2001
Received: from mail.eckpart.de ([217.6.160.186] helo=cserv.eckpart.de)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15wkVz-0002Rg-00
	for <bug-commoncpp@gnu.org>; Thu, 25 Oct 2001 09:25:43 -0400
Received: (qmail 32559 invoked from network); 25 Oct 2001 13:25:39 -0000
Received: from at13.eckpart.de (HELO epgmbh.de) (192.168.41.70)
  by cserv.eckpart.de with SMTP; 25 Oct 2001 13:25:39 -0000
Message-ID: <3BD812D3.5080107@epgmbh.de>
Date: Thu, 25 Oct 2001 15:25:39 +0200
From: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <t.maekitalo@epgmbh.de>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:0.9.4) Gecko/20010913
X-Accept-Language: de-at, de, en, en-us
MIME-Version: 1.0
To: bug-commoncpp <bug-commoncpp@gnu.org>
Subject: Bug fixed in socket.cpp
Content-Type: multipart/mixed;
 boundary="------------030102000806010605010600"
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

This is a multi-part message in MIME format.
--------------030102000806010605010600
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit

Hello,

I found 2 bugs in socket.cpp. I fixed them. Here is my diff.

Description:
1. TCPStream::timeout is not initialized when creating a tcpstream
2. if timeout is set TCPStream::underflow does never read data from the 
socket but reinitializes the receive-buffer with random data.

This has nothing to do with the problem I reported earlier today. I use 
a workaround. I set throwflag in the constructor to false and check 
errors myself. If you want me to modify the errorhandling, please tell me.


Tommi Mäkitalo

--------------030102000806010605010600
Content-Type: text/plain;
 name="socket.cpp.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="socket.cpp.diff"

923c923,924
<         bufsize(0),gbuf(NULL),pbuf(NULL)
---
>         bufsize(0),gbuf(NULL),pbuf(NULL),
>         timeout(0)
1044c1045
< 	else if(timeout)
---
> 	else if(timeout && !Socket::isPending(SOCKET_PENDING_INPUT, timeout))
1046,1051c1047,1049
< 		if(!Socket::isPending(SOCKET_PENDING_INPUT, timeout))
< 		{
< 			clear(ios::failbit | rdstate());
< 			Error(SOCKET_TIMEOUT_ERROR);
< 			return EOF;
< 		}
---
> 		clear(ios::failbit | rdstate());
> 		Error(SOCKET_TIMEOUT_ERROR);
> 		return EOF;

--------------030102000806010605010600--



From nic@nscompservices.demon.co.uk Sun Oct 28 11:51:16 2001
Received: from tele-post-20.mail.demon.net ([194.217.242.20])
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15xt9Y-0006fX-00
	for <bug-commoncpp@gnu.org>; Sun, 28 Oct 2001 11:51:16 -0500
Received: from nscompservices.demon.co.uk ([212.229.99.249])
	by tele-post-20.mail.demon.net with esmtp (Exim 2.12 #2)
	id 15xt9X-0006Kx-0K
	for bug-commoncpp@gnu.org; Sun, 28 Oct 2001 16:51:15 +0000
Received: from nic by nscompservices.demon.co.uk with local (Exim 3.32 #1 (Debian))
	id 15xu5f-0007H9-00
	for <bug-commoncpp@gnu.org>; Sun, 28 Oct 2001 17:51:19 +0000
Subject: URLStream problem
From: Nic Strong <nic@nscompservices.demon.co.uk>
To: bug-commoncpp@gnu.org
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
X-Mailer: Evolution/0.12.99 (Preview Release)
Date: 28 Oct 2001 17:51:19 +0000
Message-Id: <1004291479.13839.15.camel@nscompservices>
Mime-Version: 1.0
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

I had trouble getting the URLStream to recognise a specfic port in a url
e.g. http://localhost:2134.

Adding:
	strncpy( urlbuf, url, 1024 );

on entry to the if statement at the top of Get() in URLStream seems to
fix this.

Diffs are:

*** url.cpp     Thu Oct  4 19:28:22 2001
--- ../../CommonC++-1.6.3.mods/posix/url.cpp   Sun Oct 28 17:40:53 2001
***************
*** 378,383 ****
--- 378,384 ----
 
        if(!proxyPort)
        {
+               strncpy(urlbuf, url, 1024);
                ep = strchr(urlbuf, ':');
                if(ep)
                {


Cheers,
Nic


From t.maekitalo@epgmbh.de Mon Oct 29 04:53:40 2001
Received: from mail.eckpart.de ([217.6.160.186] helo=cserv.eckpart.de)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15y96y-0004Am-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 04:53:40 -0500
Received: (qmail 20077 invoked from network); 29 Oct 2001 09:53:36 -0000
Received: from at13.eckpart.de (HELO epgmbh.de) (192.168.41.70)
  by cserv.eckpart.de with SMTP; 29 Oct 2001 09:53:36 -0000
Message-ID: <3BDD2720.4080804@epgmbh.de>
Date: Mon, 29 Oct 2001 10:53:36 +0100
From: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <t.maekitalo@epgmbh.de>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:0.9.4) Gecko/20010923
X-Accept-Language: de-at, de, en, en-us
MIME-Version: 1.0
To: bug-commoncpp <bug-commoncpp@gnu.org>
Subject: another bug in socket.cpp
Content-Type: multipart/mixed;
 boundary="------------030609080100040102010506"
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

This is a multi-part message in MIME format.
--------------030609080100040102010506
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit

Hello,

I just found and fixed another bug in socket.cpp. It is just another 
case of the former bug I reported. Here is my diff. I used my already 
fixed socket.cpp as a base.

By the way: I included just a -Wall to my compileroptions (gcc). It 
reports me severel warnings 'unused parameter'. They can be easiliy 
fixed. What do you think?


Tommi Mäkitalo

--------------030609080100040102010506
Content-Type: text/plain;
 name="socket.cpp.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="socket.cpp.diff"

1013,1020c1013,1017
< 		else if(timeout)
< 		{
< 			if(!Socket::isPending(SOCKET_PENDING_INPUT, timeout))
< 			{
< 				clear(ios::failbit | rdstate());
< 				Error(SOCKET_TIMEOUT_ERROR);
< 				return EOF;
< 			}
---
> 		else if(timeout && !Socket::isPending(SOCKET_PENDING_INPUT, timeout))
>         {
>             clear(ios::failbit | rdstate());
>             Error(SOCKET_TIMEOUT_ERROR);
>             return EOF;

--------------030609080100040102010506--



From mad@brasmap.com.br Mon Oct 29 06:02:41 2001
Received: from acate.com.br ([200.215.17.89] helo=gw.acate.com.br)
	by fencepost.gnu.org with esmtp (Exim 3.22 #1 (Debian))
	id 15yABk-0001a1-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 06:02:41 -0500
Received: from cli003paula ([192.168.1.13])
	by gw.acate.com.br (8.9.3/8.9.3) with SMTP id JAA10820
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 09:02:31 -0200
From: "Marcelo Dalmas" <mad@brasmap.com.br>
To: <bug-commoncpp@gnu.org>
Date: Mon, 29 Oct 2001 09:03:40 -0200
Message-ID: <NFBBKMPNOPAAIBBFJEDGEEEKCAAA.mad@brasmap.com.br>
MIME-Version: 1.0
Content-Type: multipart/mixed;
	boundary="----=_NextPart_000_0000_01C16058.9ADABEA0"
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
Importance: Normal
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200
Subject: (no subject)
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

This is a multi-part message in MIME format.

------=_NextPart_000_0000_01C16058.9ADABEA0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

Hi!

I Detach() a thread and verify if it isRunning(). But isRunning() look for
_tid != 0, and _tid = 0 only other thread call Terminate().
I modify execHandler() to do _tid = 0 before call pthread_exit().
It's ok or I'm doing something wrong ?

Tanks

Marcelo Dalmas
BRASMAP Sistemas
www.brasmap.com
Fone/Fax: (48) 333-2218 ramal 2114
------=_NextPart_000_0000_01C16058.9ADABEA0
Content-Type: application/x-gzip;
	name="test.tar.gz"
Content-Transfer-Encoding: base64
Content-Disposition: attachment;
	filename="test.tar.gz"

H4sIAGtC3TsAA+2WW2+bMBSA84p/xVk3VTAGAcKlol2ULV2nSmlXrelzS4mTWCOAwOlFU/vbZ+OQ
oDZVX5ZG0/wpCtjniu1zgOKStlubxWIEgcWuTsftuI3rkpYVdHy/43qe5bN5z7eDFngbzkvSalG+
/yfRLzwmCd5QDL7Bvv/y/jtBUO8/OyYdNh84Ftv/DaUjadA/O4PPMNF11D8afPl+zgZXcTxJ50ac
pWMyAcMYJ9GkvAJ0fNofXBx+W6dC0jiZjzDXGhx/XaeRkOvyCqEoSULgZw4h/i/uzTjPkfJBZblo
wC5VIvyujqiBkVWaS3Um5IG0bS/fP09V//WqbihGVf+u+1L92y7v+Yv+b/ui/h1P1v9b8H5RunBA
spIWOJp10WoujnW9LWrYnD4TzKK4yMo1AjpljkZcgOIkKks4uR9WUxBCPr9OSAxijH4jMQ4RMB5r
PVXbR3lBbiKKQ6TcZGQEP+cpnxWDI5JGCR8+7CNUG4Vhw555Voa4mDFFiivDOJtTODiAnbX6O1yE
01EifFZRVopVcO7ymZNK0jBWzhOMc9XmB1tb62uRe8Pb0tlC9CQXklKYRWSRwXIpP4pVZr02xbfQ
XLlGmtd4nBUYShoVVNVM02z4RorwYHQPMY3iqTC9nbIPAbWWkJI9YErSiappLLhSiqfj67kKskiE
lFBw5UkziPKwuTgQTdiyPIu21Md3hDKXT596hBNMMQhvbIkRQtuuwu0h+r+oV/YGMPOIxtO/HOO1
7z+vs/r+7/D+b1u+bcn+/xYYhgH9bDbL0r6uG7bpm047z0py1zgUj8pwOocfMQVwwfZDZy90HHDY
mxvpuv6quXJUkMra8cEOQicIPUtY93pguLb3KQCdX/ag10OgkLH6LhfmlyPRMejU6F5SMtJgdxeq
QR4VOKUaU1caY6N7mlEyvmcGrHVAJVq+Kwyl9sobg3p6MRiwWV2pnbNOavHxGi2Fv54eEP/xbq7U
vbzEdEhmuFAp+2dt55J9ofKx9h93FIlEIpFIJBKJRCKRSCQSiUQikUgk2+YPHNQnngAoAAA=

------=_NextPart_000_0000_01C16058.9ADABEA0--



From t.maekitalo@epgmbh.de Mon Oct 29 06:31:18 2001
Received: from mail.eckpart.de ([217.6.160.186] helo=cserv.eckpart.de)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15yAdS-0004DZ-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 06:31:18 -0500
Received: (qmail 20473 invoked from network); 29 Oct 2001 11:31:15 -0000
Received: from at13.eckpart.de (HELO epgmbh.de) (192.168.41.70)
  by cserv.eckpart.de with SMTP; 29 Oct 2001 11:31:15 -0000
Message-ID: <3BDD3E03.8010906@epgmbh.de>
Date: Mon, 29 Oct 2001 12:31:15 +0100
From: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <t.maekitalo@epgmbh.de>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; de-AT; rv:0.9.4) Gecko/20010923
X-Accept-Language: de-at, de, en, en-us
MIME-Version: 1.0
To: bug-commoncpp <bug-commoncpp@gnu.org>
Subject: problems with cvs
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

Hello,

I'm trying to use the cvs-version of commonc++, but I haven't managed it 
yet. Maybe someone can give me a hint. (I'm new to 
cvs/autoconf/automake, but I try to learn)

This is, what I have done:
- I set my CVSROOT to :pserver:anoncvs@subersions.gnu.org:/cvs
- I did a cvs checkout commoncpp. This checked out the files
- I run 'aclocal -I m4' in the commoncpp-directory
- I run 'autoconf'; this gave me the warning: configure.in:21: warning: 
AC_COMPILE_IFELSE was called before AC_MINIX
- I run 'automake'; this created a configure-script
- I run 'configure --prefix=/usr'; this gave me a error: 'sed: can't 
read confdefs.h: No such file or directory'

I stopped here, because I feel, that there is something wrong?


Tommi Mäkitalo



From dyfet@ostel.com Mon Oct 29 06:39:02 2001
Received: from [65.188.113.57] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15yAkv-0004Wi-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 06:39:01 -0500
Received: from ostel.com (home [172.16.1.254])
	by home.sys (Postfix) with ESMTP
	id 1384C1C8CD; Mon, 29 Oct 2001 07:39:53 -0500 (EST)
Message-ID: <3BDD4E18.1050206@ostel.com>
Date: Mon, 29 Oct 2001 07:39:52 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.3) Gecko/20010802
X-Accept-Language: en-us
MIME-Version: 1.0
To: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <t.maekitalo@epgmbh.de>
Cc: bug-commoncpp <bug-commoncpp@gnu.org>
Subject: Re: problems with cvs
References: <3BDD3E03.8010906@epgmbh.de>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

There is a special script, "reconfig", which should do everything to 
take a cvs copy and built a complete local copy out.  Just use 
./reconfig.  It may report some errors, but that should work....however, 
if there are changes in a more recent copy of autoconf that causes that 
error I might have to restructure configure.in.

David

Tommi Mäkitalo wrote:

> Hello,
>
> I'm trying to use the cvs-version of commonc++, but I haven't managed 
> it yet. Maybe someone can give me a hint. (I'm new to 
> cvs/autoconf/automake, but I try to learn)
>
> This is, what I have done:
> - I set my CVSROOT to :pserver:anoncvs@subersions.gnu.org:/cvs
> - I did a cvs checkout commoncpp. This checked out the files
> - I run 'aclocal -I m4' in the commoncpp-directory
> - I run 'autoconf'; this gave me the warning: configure.in:21: 
> warning: AC_COMPILE_IFELSE was called before AC_MINIX
> - I run 'automake'; this created a configure-script
> - I run 'configure --prefix=/usr'; this gave me a error: 'sed: can't 
> read confdefs.h: No such file or directory'
>
> I stopped here, because I feel, that there is something wrong?
>
>
> Tommi Mäkitalo
>
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp





From dyfet@ostel.com Mon Oct 29 07:04:27 2001
Received: from [65.188.113.57] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15yB9X-00061p-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 07:04:27 -0500
Received: by home.sys (Postfix, from userid 501)
	id 71A891C8CA; Mon, 29 Oct 2001 08:05:19 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id 6A9951C8C9; Mon, 29 Oct 2001 08:05:19 -0500 (EST)
Date: Mon, 29 Oct 2001 08:05:19 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: <freddy77@angelfire.com>,
	<cplusplus-devel@lists.sourceforge.com>, <bug-commoncpp@gnu.org>,
	<bayonne-devel@lists.sourceforge.net>
Subject: Common C++ 1.6.4 and 1.7.0
Message-ID: <Pine.LNX.4.33L2.0110290757270.8584-100000@home>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

I am going to try and release Common C++ 1.6.4 and 1.7.0 today and/or
tomorrow.  1.6.4 has a few small patches and should be production stable
for current gnucomm development such as GNU Bayonne.  1.7.0 uses the
entirely new combined source tree Frediano had spent a lot of time working
on and has a substancial number of changes in class organization.  These
changes will be finalized for a 2.0 release later in the year.

At some point soon most of the remaining GNUCOMM common API packages will
be updated for the new Common C++, including ccScript and ccRTP.  Most of
the changes in these packages will likely involve similar use of macros in
the headers so that these can also be cleanly built under both win32 and
posix systems.  When this work is complete, these new packages, and Common
C++ 1.7.0 (or by then 2.0) will become the base set of packages for
ongoing GNUCOMM work.

David




From rob.kirkbride@thales-is.com Mon Oct 29 11:43:04 2001
Received: from gwsmtp.thomson-csf.com ([195.101.39.226])
	by fencepost.gnu.org with esmtp (Exim 3.22 #1 (Debian))
	id 15yFV9-0001rr-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 11:43:03 -0500
Received: from thomplex.thomson-csf.com (200.3.2.2) by gwsmtp.thomson-csf.com (NPlex 5.1.053)
        id 3BDD36580000D437 for bug-commoncpp@gnu.org; Mon, 29 Oct 2001 17:46:46 +0100
Received: from thomplex.thomson-csf.com (200.3.2.2) by thomplex.thomson-csf.com (NPlex 5.1.036)
        id 3BDD298D0000E219 for bug-commoncpp@gnu.org; Mon, 29 Oct 2001 17:41:10 +0100
Received: from zaphod (141.20.119.50) by central03.uk.syseca.thomson-csf.com (NPlex 5.0.048)
        id 3BAEFB78000064B3 for bug-commoncpp@gnu.org; Mon, 29 Oct 2001 16:40:41 +0000
Date: Mon, 29 Oct 2001 16:43:25 +0000
From: Robert Kirkbride <rob.kirkbride@thales-is.com>
To: bug-commoncpp@gnu.org
Subject: Not able to build on Tru64 4.0g
Message-ID: <20011029164325.C13966@zaphod>
Mime-Version: 1.0
Content-Type: text/plain; format=flowed; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Mailer: Balsa 1.2.1
Lines: 36
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

I've been attempting to compile version 1.6.4 on Tru 64 Unix using GCC 
version 3.01.

The configure stage appears to work fine. However, upon hitting the 
first compile, errors starting with that below are produced.

Making all in posix
make[1]: Entering directory `/usr/users/rk/CommonC++-1.6.4/posix'
/bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I. 
-I../posix     -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -c 
inaddr.cpp
rm -f .libs/inaddr.lo
c++ -DHAVE_CONFIG_H -I. -I. -I. -I../posix -g -O2 -D_GNU_SOURCE 
-D_REENTRANT -D_THREAD_SAFE -c inaddr.cpp  -DPIC -o .libs/inaddr.lo
In file included from config.h:402,
                  from inaddr.cpp:41:
/usr/include/pthread.h:981: `valid' was not declared in this scope
/usr/include/pthread.h:981: invalid data member initialization
/usr/include/pthread.h:981: (use `=' to initialize static data members)
/usr/include/pthread.h:982: `reserved' was not declared in this scope
/usr/include/pthread.h:982: cannot initialize arrays using this syntax
/usr/include/pthread.h:994: `valid' was not declared in this scope
/usr/include/pthread.h:994: invalid data member initialization
/usr/include/pthread.h:995: `name' was not declared in this scope
/usr/include/pthread.h:995: invalid data member initialization
/usr/include/pthread.h:995: declaration of 
`char*__pthread_paddock_t::_Pfield'
/usr/include/pthread.h:994: conflicts with previous declaration

I've tried a few basic test programs which #include pthread.h and they 
compile fine.

Any ideas?

Rob Kirkbride
Thales Information Systems


From dyfet@ostel.com Mon Oct 29 12:03:00 2001
Received: from [65.188.113.57] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15yFoR-0002id-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 12:03:00 -0500
Received: by home.sys (Postfix, from userid 501)
	id C0DF01C8DC; Mon, 29 Oct 2001 13:03:53 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id BB90818287; Mon, 29 Oct 2001 13:03:53 -0500 (EST)
Date: Mon, 29 Oct 2001 13:03:53 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: <freddy77@angelfire.com>,
	<cplusplus-devel@lists.sourceforge.net>, <bug-commoncpp@gnu.org>
Subject: 1.9.0 progress
Message-ID: <Pine.LNX.4.33L2.0110291302060.24092-100000@home>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

I had such rapid progress on the new 1.9.0 code base for the 2.0 release
that I am going to bypass 1.7.0 and I expect 1.9.0 to be ready in a day or
two.  This adds namespace support and std::exception based exception
handling.  Rather than absort two sets of changes over time with the
unified source directory and the exception/namespace stuff, I am going to
release both at once...

David



From dyfet@ostel.com Mon Oct 29 13:22:40 2001
Received: from [65.188.113.57] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15yH3X-0006uk-00
	for <bug-commoncpp@gnu.org>; Mon, 29 Oct 2001 13:22:40 -0500
Received: by home.sys (Postfix, from userid 501)
	id E988E1CB75; Mon, 29 Oct 2001 14:23:33 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id E27FE1CB74; Mon, 29 Oct 2001 14:23:33 -0500 (EST)
Date: Mon, 29 Oct 2001 14:23:33 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: Robert Kirkbride <rob.kirkbride@thales-is.com>
Cc: <bug-commoncpp@gnu.org>
Subject: Re: Not able to build on Tru64 4.0g
In-Reply-To: <20011029164325.C13966@zaphod>
Message-ID: <Pine.LNX.4.33L2.0110291423010.30987-100000@home>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

This sounds like a strange interaction between the pthread header and
perhaps some of the defines setup in posix/config.h.

On Mon, 29 Oct 2001, Robert Kirkbride wrote:

> I've been attempting to compile version 1.6.4 on Tru 64 Unix using GCC
> version 3.01.
>
> The configure stage appears to work fine. However, upon hitting the
> first compile, errors starting with that below are produced.
>
> Making all in posix
> make[1]: Entering directory `/usr/users/rk/CommonC++-1.6.4/posix'
> /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I.
> -I../posix     -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -c
> inaddr.cpp
> rm -f .libs/inaddr.lo
> c++ -DHAVE_CONFIG_H -I. -I. -I. -I../posix -g -O2 -D_GNU_SOURCE
> -D_REENTRANT -D_THREAD_SAFE -c inaddr.cpp  -DPIC -o .libs/inaddr.lo
> In file included from config.h:402,
>                   from inaddr.cpp:41:
> /usr/include/pthread.h:981: `valid' was not declared in this scope
> /usr/include/pthread.h:981: invalid data member initialization
> /usr/include/pthread.h:981: (use `=' to initialize static data members)
> /usr/include/pthread.h:982: `reserved' was not declared in this scope
> /usr/include/pthread.h:982: cannot initialize arrays using this syntax
> /usr/include/pthread.h:994: `valid' was not declared in this scope
> /usr/include/pthread.h:994: invalid data member initialization
> /usr/include/pthread.h:995: `name' was not declared in this scope
> /usr/include/pthread.h:995: invalid data member initialization
> /usr/include/pthread.h:995: declaration of
> `char*__pthread_paddock_t::_Pfield'
> /usr/include/pthread.h:994: conflicts with previous declaration
>
> I've tried a few basic test programs which #include pthread.h and they
> compile fine.
>
> Any ideas?
>
> Rob Kirkbride
> Thales Information Systems
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>



From dyfet@ostel.com Tue Oct 30 11:35:15 2001
Received: from [65.188.113.57] (helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.22 #1 (Debian))
	id 15ybr9-0001ir-00
	for <bug-commoncpp@gnu.org>; Tue, 30 Oct 2001 11:35:15 -0500
Received: by home.sys (Postfix, from userid 501)
	id 5AF4E1D2D2; Tue, 30 Oct 2001 12:36:15 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id 547071D2D1; Tue, 30 Oct 2001 12:36:15 -0500 (EST)
Date: Tue, 30 Oct 2001 12:36:15 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: <bayonne-devel@lists.sourceforge.net>, <bug-commoncpp@gnu.org>,
	<cplusplus-devel@lists.sourceforge.net>
Subject: Common C++ 1.9.0
Message-ID: <Pine.LNX.4.33L2.0110301228270.3507-100000@home>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Sender: bug-commoncpp-admin@gnu.org
Errors-To: bug-commoncpp-admin@gnu.org
X-BeenThere: bug-commoncpp@gnu.org
X-Mailman-Version: 2.0.5
Precedence: bulk
List-Help: <mailto:bug-commoncpp-request@gnu.org?subject=help>
List-Post: <mailto:bug-commoncpp@gnu.org>
List-Subscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=subscribe>
List-Id: Bug reports for Common C++ <bug-commoncpp.gnu.org>
List-Unsubscribe: <http://mail.gnu.org/mailman/listinfo/bug-commoncpp>,
	<mailto:bug-commoncpp-request@gnu.org?subject=unsubscribe>
List-Archive: <http://mail.gnu.org/pipermail/bug-commoncpp/>

An initial code set for this had been completed last night, and I believe
Frediano has at least partially tested the win32 native builds for it.
I have reorganized the sourceforge cvs around the single source
directory and I have been able to validate the demo apps against the new
code under GNU/Linux.

I am going to do a seperate checkin of this new tree at Savannah under the
module name commoncpp and I am thinking of chaning the tarball for this
release from commonc++ to commoncpp because it would make the lsm people
much happier with their automated scripts which always rejected the "++"
in the package name.

I think it should be possible to build a native ccRTP win32 dll with the
current release, and this should make it much easier to create portable
IP phone clients with GNU ccRTP and GNU Common C++.  I am going to try and
update ccRTP and other packages for this new Common C++ release later
this week.

I think the target date for release should be Friday.  This will let
different people test the cvs stuff more completely, and perhaps provide
an oppertunity to update related packages.

David






