From xocolatl@noos.fr Fri Feb 01 10:18:41 2002
Received: from zola.noos.net ([212.198.2.76] helo=smtp.noos.fr)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16WfSb-0004zw-00
	for <bug-commoncpp@gnu.org>; Fri, 01 Feb 2002 10:18:41 -0500
Received: (qmail 50915081 invoked by uid 0); 1 Feb 2002 15:18:40 -0000
Received: from unknown (HELO there) ([195.132.197.33]) (envelope-sender <xocolatl@noos.fr>)
          by 212.198.2.76 (qmail-ldap-1.03) with SMTP
          for <bug-commoncpp@gnu.org>; 1 Feb 2002 15:18:40 -0000
Content-Type: text/plain;
  charset="iso-8859-1"
From: Juan Barragan <xocolatl@noos.fr>
To: bug-commoncpp@gnu.org
Subject: Constructing classes
Date: Fri, 1 Feb 2002 15:50:11 +0100
X-Mailer: KMail [version 1.3.1]
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Message-Id: <E16WfSb-0004zw-00@fencepost.gnu.org>
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've been working with g++ 2.95.3 and, well I dont know if the following is 
a bug, I defined a class like:

class MyClass {
	public:
	datastuff;
	Some_data_created_with_the_data_stuff;
	MyClass();
	//With copy and assignement constructors-operators
	MyClass* next;
	private:
	otherstuff;
};
	and then I create a linked list. The problem being with expresions like

	MyClass* p=new MyClass(rigth_stuff);

	Sometimes, p->Some_data_created..., does give right results, sometimes it 
doesnt.

	I'll be pleased to hear about that, if that's a problem of the compiler or 
is just me (just another, poor newbye)

	Thanks for any help.

	J.Barragan


From psycho@tex.ro Sun Feb 03 07:03:04 2002
Received: from psychophobia.tex.ro ([213.154.142.82] helo=tex.ro)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16XLMO-0005hz-00
	for <bug-commoncpp@gnu.org>; Sun, 03 Feb 2002 07:03:04 -0500
Received: from PerfectSense ([192.168.1.111])
	by tex.ro (8.11.0/8.11.0) with SMTP id g13FE9709299
	for <bug-commoncpp@gnu.org>; Sun, 3 Feb 2002 17:14:10 +0200
Message-ID: <004501c1acab$74793490$0103a8c0@PerfectSense>
From: "Vladimir Ciobanu" <psycho@tex.ro>
To: <bug-commoncpp@gnu.org>
Subject: Problem with commonc++-??? and gcc-3.0.3
Date: Sun, 3 Feb 2002 14:08:13 +0200
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 6.00.2462.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2462.0000
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 just installed gcc-3.0.3 and I've got some errors with commomc++-1.9.5
presented at the end of the email. I am wondering whether I am doing
something wrong or is it a known problem with that current commomc++
package. Are they any patches which would make it compile with gcc-3.0.3 or
is it going to be supported in later packages ? Any answer will be
apreciated.

/bin/sh ../libtool --mode=compile
-DHAVE_CONFIG_H -I. -I. -I. -I../src     -
I../src  -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -c exception.cpp
rm -f .libs/exception.lo
c++ -DHAVE_CONFIG_H -I. -I. -I. -I../src -I../src -g -O2 -D_GNU_SOURCE -D_RE
ENTR
ANT -D_THREAD_SAFE -c exception.cpp  -fPIC -DPIC -o
.libs/exception.lo
exception.cpp:50: syntax error before `::' token
exception.cpp:54: syntax error before `::' token
exception.cpp:57: syntax error before `::' token
exception.cpp:64: syntax error before `::' token
exception.cpp:68: syntax error before `::' token
make[1]: *** [exception.lo] Error 1
make[1]: Leaving directory `/var/ftp/pub/linux/libs/CommonC++-1.9.5/src'
make: *** [all-recursive] Error 1

Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.0.3/specs
Configured with:
../gcc-3.0.3/configure --enable-languages=c,c++ --enable-threads
Thread model: posix
gcc version 3.0.3


Thank you




From danielb@obfuscation.dyndns.org Sun Feb 03 20:58:34 2002
Received: from out4.mx.nwbl.wi.voyager.net ([169.207.1.77])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16XYOw-000702-00
	for <bug-commoncpp@gnu.org>; Sun, 03 Feb 2002 20:58:34 -0500
Received: from pop5.nwbl.wi.voyager.net (pop5.nwbl.wi.voyager.net [169.207.3.83])
	by out4.mx.nwbl.wi.voyager.net (8.11.1/8.11.4/1.7) with ESMTP id g141wX570828
	for <bug-commoncpp@gnu.org>; Sun, 3 Feb 2002 19:58:33 -0600 (CST)
Received: from obfuscation.dyndns.org (d106.as21.nwbl0.wi.voyager.net [169.207.138.234])
	by pop5.nwbl.wi.voyager.net (8.10.2/8.10.2) with ESMTP id g141wWv18924
	for <bug-commoncpp@gnu.org>; Sun, 3 Feb 2002 19:58:32 -0600 (CST)
Received: from danielb by obfuscation.dyndns.org with local (Exim 3.34 #1 (Debian))
	id 16XYMc-0006lk-00
	for <bug-commoncpp@gnu.org>; Sun, 03 Feb 2002 19:56:10 -0600
Date: Sun, 3 Feb 2002 19:56:09 -0600
From: Daniel E Baumann <danielb@freedevelopers.net>
To: bug-commoncpp@gnu.org
Subject: Re: Problem with commonc++-??? and gcc-3.0.3
Message-ID: <20020204015609.GA25929@freedevelopers.net>
References: <004501c1acab$74793490$0103a8c0@PerfectSense>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <004501c1acab$74793490$0103a8c0@PerfectSense>
User-Agent: Mutt/1.3.27i
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/>

On Sun, Feb 03, 2002 at 02:08:13PM +0200, Vladimir Ciobanu wrote:
> 
>    I just installed gcc-3.0.3 and I've got some errors with commomc++-1.9.5
> presented at the end of the email. I am wondering whether I am doing
> something wrong or is it a known problem with that current commomc++
> package. Are they any patches which would make it compile with gcc-3.0.3 or
> is it going to be supported in later packages ? Any answer will be
> apreciated.
> 
> /bin/sh ../libtool --mode=compile
> -DHAVE_CONFIG_H -I. -I. -I. -I../src     -
> I../src  -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -c exception.cpp
> rm -f .libs/exception.lo
> c++ -DHAVE_CONFIG_H -I. -I. -I. -I../src -I../src -g -O2 -D_GNU_SOURCE -D_RE
> ENTR
> ANT -D_THREAD_SAFE -c exception.cpp  -fPIC -DPIC -o
> .libs/exception.lo
> exception.cpp:50: syntax error before `::' token
> exception.cpp:54: syntax error before `::' token
> exception.cpp:57: syntax error before `::' token
> exception.cpp:64: syntax error before `::' token
> exception.cpp:68: syntax error before `::' token
> make[1]: *** [exception.lo] Error 1
> make[1]: Leaving directory `/var/ftp/pub/linux/libs/CommonC++-1.9.5/src'
> make: *** [all-recursive] Error 1
> 
> Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.0.3/specs
> Configured with:
> ../gcc-3.0.3/configure --enable-languages=c,c++ --enable-threads
> Thread model: posix
> gcc version 3.0.3

If you read earlier messages this error is due to a typo in
exception.h. You basically have to change the part that goes:

#if defined(HAVE_EXCEPTION) to

#if defined(HAVE_EXCEPTION_HANDLING)

Cheers,
Dan
-- 
Daniel E Baumann      danielb@freedevelopers.net 

***Free Dmitry Sklyarov! Boycott Adobe! Repeal DMCA!***

And if cynics ridicule freedom, ridicule community...if ``hard nosed 
realists'' say that profit is the only ideal...just ignore them, and use 
copyleft all the same.
      -- RMS


From ianc@band-x.net Mon Feb 04 11:44:21 2002
Received: from mail1.band-x.net ([213.166.0.230] helo=mail.band-x.net)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16XmE8-0003R5-00
	for <bug-commoncpp@gnu.org>; Mon, 04 Feb 2002 11:44:20 -0500
Received: (qmail 24210 invoked from network); 4 Feb 2002 16:44:14 -0000
Received: from unknown (HELO LGBBANDX242) (213.166.3.59)
  by mail1.band-x.net with SMTP; 4 Feb 2002 16:44:14 -0000
Message-ID: <00d401c1ad9a$25bfcc20$5ca8fea9@LGBBANDX242>
From: "Ian Campbell" <ianc@band-x.net>
To: <bug-commoncpp@gnu.org>
Subject: Problem with copying constructor and unbuffered TCPStream
Date: Mon, 4 Feb 2002 16:36:50 -0000
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 5.50.4133.2400
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400
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 David et al,
    I discovered a problem with the using the copy constructor and TCPStream
with a buffer size of < 2. This is because the copy constructor does not
make gbuf and pbuf NULL when copying which in turn causes the destructor to
segmentation fault. Here is a patch for this:

--- socket.cpp~ Mon Oct 29 12:32:00 2001
+++ socket.cpp Sun Feb  3 09:43:30 2002
@@ -959,6 +959,7 @@
  if(size < 2)
  {
   bufsize = 1;
+  gbuf = pbuf = NULL;
   return;
  }

Cheers,

Ian Campbell
Band-X



From david.durham@wcom.com Mon Feb 04 14:35:12 2002
Received: from pmesmtp02.wcom.com ([199.249.20.2])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16XotT-0007t6-00
	for <bug-commoncpp@gnu.org>; Mon, 04 Feb 2002 14:35:12 -0500
Received: from CONVERSION-DAEMON by firewall.wcom.com (PMDF V5.2-32 #42257)
 id <0GR000101X240A@firewall.wcom.com> for bug-commoncpp@gnu.org; Mon,
 4 Feb 2002 19:34:52 +0000 (GMT)
Received: from pmismtp04.wcomnet.com ([166.38.62.39])
 by firewall.wcom.com (PMDF V5.2-32 #42257)
 with ESMTP id <0GR000066X24QF@firewall.wcom.com>; Mon,
 04 Feb 2002 19:34:52 +0000 (GMT)
Received: from pmismtp04.wcomnet.com by pmismtp04.wcomnet.com
 (PMDF V5.2-33 #42258) with SMTP id <0GR000I01X1A66@pmismtp04.wcomnet.com>;
 Mon, 04 Feb 2002 19:34:51 +0000 (GMT)
Received: from wcom.com ([159.98.157.25])
 by pmismtp04.wcomnet.com (PMDF V5.2-33 #42258)
 with ESMTP id <0GR000FDLX18XZ@pmismtp04.wcomnet.com>; Mon,
 04 Feb 2002 19:34:21 +0000 (GMT)
Date: Mon, 04 Feb 2002 13:15:45 -0600
From: David Durham <david.durham@wcom.com>
Subject: Re: Questions
To: David Sugar <dyfet@ostel.com>
Cc: bug-commoncpp@gnu.org
Message-id: <3C5EDDE1.3080702@wcom.com>
MIME-version: 1.0
Content-type: text/plain; format=flowed; charset=us-ascii
Content-transfer-encoding: 7bit
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.7) Gecko/20011221
X-Accept-Language: en-us
References: <3C55B986.5000203@wcom.com> <3C56C0E4.2010003@ostel.com>
 <3C56CAC1.7020502@wcom.com> <3C56D4EE.90100@ostel.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/>

David Sugar wrote:

> Older and poorer compilers have different problems.  For example, if 
> you define a class foo in a common header that uses STL, and have an 
> instance of foo in test1.cpp and in test2.cpp, you may have template 
> generated object code in both test1.o and test2.o even when it has 
> been subroutined and is identical/duplicate function calls.  Newer 
> compilers and linkers throw away duplicate code like this.  Then there 
> was a time not all c++ compilers could compile STL...
>
> My mistake, I meant "ThreadLock" when I said RWLock :).  That's why 
> you can't find it....
>
> As for realpath, I think it would have to provide an implimentation if 
> one is not provided.  realpath is far too useful for enforcing path 
> restricted access policies.

What is the significance of the name 'ThreadLock'... 'RWLock' seems to 
make much more sense... And there may even be a better term from a CS 
textbook.




From dyfet@ostel.com Mon Feb 04 15:03:15 2002
Received: from [65.204.5.82] (helo=andromeda.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16XpKd-0000iQ-00
	for <bug-commoncpp@gnu.org>; Mon, 04 Feb 2002 15:03:15 -0500
Received: from ostel.com (localhost.localdomain [127.0.0.1])
	by andromeda.sys (Postfix) with ESMTP
	id E0B531AF7A; Mon,  4 Feb 2002 15:04:15 -0500 (EST)
Message-ID: <3C5EE93F.6070507@ostel.com>
Date: Mon, 04 Feb 2002 15:04:15 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.4) Gecko/20010914
X-Accept-Language: en-us
MIME-Version: 1.0
To: David Durham <david.durham@wcom.com>
Cc: bug-commoncpp@gnu.org
Subject: Re: Questions
References: <3C55B986.5000203@wcom.com> <3C56C0E4.2010003@ostel.com> <3C56CAC1.7020502@wcom.com> <3C56D4EE.90100@ostel.com> <3C5EDDE1.3080702@wcom.com>
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/>

Well, it does seem a strange choice since we dont have a "ThreadMutex". 
 Perhaps RWLock would have been better...

David Durham wrote:

> David Sugar wrote:
>
>> Older and poorer compilers have different problems.  For example, if 
>> you define a class foo in a common header that uses STL, and have an 
>> instance of foo in test1.cpp and in test2.cpp, you may have template 
>> generated object code in both test1.o and test2.o even when it has 
>> been subroutined and is identical/duplicate function calls.  Newer 
>> compilers and linkers throw away duplicate code like this.  Then 
>> there was a time not all c++ compilers could compile STL...
>>
>> My mistake, I meant "ThreadLock" when I said RWLock :).  That's why 
>> you can't find it....
>>
>> As for realpath, I think it would have to provide an implimentation 
>> if one is not provided.  realpath is far too useful for enforcing 
>> path restricted access policies.
>
>
> What is the significance of the name 'ThreadLock'... 'RWLock' seems to 
> make much more sense... And there may even be a better term from a CS 
> textbook.
>
>




From david.durham@wcom.com Mon Feb 04 15:11:09 2002
Received: from dgesmtp01.wcom.com ([199.249.16.16])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16XpSG-00011x-00
	for <bug-commoncpp@gnu.org>; Mon, 04 Feb 2002 15:11:08 -0500
Received: from CONVERSION-DAEMON by firewall.wcom.com (PMDF V5.2-33 #42260)
 id <0GR000C01YPTP5@firewall.wcom.com> for bug-commoncpp@gnu.org; Mon,
 4 Feb 2002 20:10:41 +0000 (GMT)
Received: from pmismtp02.wcomnet.com ([166.38.62.37])
 by firewall.wcom.com (PMDF V5.2-33 #42260)
 with ESMTP id <0GR000C0WYPSLA@firewall.wcom.com>; Mon,
 04 Feb 2002 20:10:40 +0000 (GMT)
Received: from pmismtp02.wcomnet.com by pmismtp02.wcomnet.com
 (PMDF V5.2-33 #42259) with SMTP id <0GR000F01YPHK1@pmismtp02.wcomnet.com>;
 Mon, 04 Feb 2002 20:10:40 +0000 (GMT)
Received: from wcom.com ([159.98.157.25])
 by pmismtp02.wcomnet.com (PMDF V5.2-33 #42259)
 with ESMTP id <0GR000BKDYPDO5@pmismtp02.wcomnet.com>; Mon,
 04 Feb 2002 20:10:26 +0000 (GMT)
Date: Mon, 04 Feb 2002 13:51:50 -0600
From: David Durham <david.durham@wcom.com>
Subject: Re: Questions
To: David Sugar <dyfet@ostel.com>
Cc: bug-commoncpp@gnu.org
Message-id: <3C5EE656.5070808@wcom.com>
MIME-version: 1.0
Content-type: text/plain; format=flowed; charset=us-ascii
Content-transfer-encoding: 7bit
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.7) Gecko/20011221
X-Accept-Language: en-us
References: <3C55B986.5000203@wcom.com> <3C56C0E4.2010003@ostel.com>
 <3C56CAC1.7020502@wcom.com> <3C56D4EE.90100@ostel.com>
 <3C5EDDE1.3080702@wcom.com> <3C5EE93F.6070507@ostel.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/>

Furthermore,
ost::Mutex has EnterMutex() and LeaveMutex()

I mean, you enter and leave a critical section, but you lock and unlock 
a mutex...   ThreadLock seemed to have it right there... Am I wrong here? :)


I'm a stickler for names, myself.... I can't explain it, but I think 
things should always be named most appropriately...

-- Davy

David Sugar wrote:

> Well, it does seem a strange choice since we dont have a 
> "ThreadMutex". Perhaps RWLock would have been better...
>
> David Durham wrote:
>
>> David Sugar wrote:
>>
>>> Older and poorer compilers have different problems.  For example, if 
>>> you define a class foo in a common header that uses STL, and have an 
>>> instance of foo in test1.cpp and in test2.cpp, you may have template 
>>> generated object code in both test1.o and test2.o even when it has 
>>> been subroutined and is identical/duplicate function calls.  Newer 
>>> compilers and linkers throw away duplicate code like this.  Then 
>>> there was a time not all c++ compilers could compile STL...
>>>
>>> My mistake, I meant "ThreadLock" when I said RWLock :).  That's why 
>>> you can't find it....
>>>
>>> As for realpath, I think it would have to provide an implimentation 
>>> if one is not provided.  realpath is far too useful for enforcing 
>>> path restricted access policies.
>>
>>
>>
>> What is the significance of the name 'ThreadLock'... 'RWLock' seems 
>> to make much more sense... And there may even be a better term from a 
>> CS textbook.
>>
>>
>
>





From dyfet@ostel.com Mon Feb 04 15:18:41 2002
Received: from [65.204.5.82] (helo=andromeda.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16XpZZ-0001Jl-00
	for <bug-commoncpp@gnu.org>; Mon, 04 Feb 2002 15:18:41 -0500
Received: from ostel.com (localhost.localdomain [127.0.0.1])
	by andromeda.sys (Postfix) with ESMTP
	id A0BB01DE2F; Mon,  4 Feb 2002 15:19:41 -0500 (EST)
Message-ID: <3C5EECDD.5010909@ostel.com>
Date: Mon, 04 Feb 2002 15:19:41 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.4) Gecko/20010914
X-Accept-Language: en-us
MIME-Version: 1.0
To: David Durham <david.durham@wcom.com>
Cc: bug-commoncpp@gnu.org
Subject: Re: Questions
References: <3C55B986.5000203@wcom.com> <3C56C0E4.2010003@ostel.com> <3C56CAC1.7020502@wcom.com> <3C56D4EE.90100@ostel.com> <3C5EDDE1.3080702@wcom.com> <3C5EE93F.6070507@ostel.com> <3C5EE656.5070808@wcom.com>
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/>

The original win32 port of class Mutex was as a critical section, so the 
terminology got back-ported :).

David Durham wrote:

> Furthermore,
> ost::Mutex has EnterMutex() and LeaveMutex()
>
> I mean, you enter and leave a critical section, but you lock and 
> unlock a mutex...   ThreadLock seemed to have it right there... Am I 
> wrong here? :)
>
>
> I'm a stickler for names, myself.... I can't explain it, but I think 
> things should always be named most appropriately...
>
> -- Davy
>
> David Sugar wrote:
>
>> Well, it does seem a strange choice since we dont have a 
>> "ThreadMutex". Perhaps RWLock would have been better...
>>
>> David Durham wrote:
>>
>>> David Sugar wrote:
>>>
>>>> Older and poorer compilers have different problems.  For example, 
>>>> if you define a class foo in a common header that uses STL, and 
>>>> have an instance of foo in test1.cpp and in test2.cpp, you may have 
>>>> template generated object code in both test1.o and test2.o even 
>>>> when it has been subroutined and is identical/duplicate function 
>>>> calls.  Newer compilers and linkers throw away duplicate code like 
>>>> this.  Then there was a time not all c++ compilers could compile 
>>>> STL...
>>>>
>>>> My mistake, I meant "ThreadLock" when I said RWLock :).  That's why 
>>>> you can't find it....
>>>>
>>>> As for realpath, I think it would have to provide an implimentation 
>>>> if one is not provided.  realpath is far too useful for enforcing 
>>>> path restricted access policies.
>>>
>>>
>>>
>>>
>>> What is the significance of the name 'ThreadLock'... 'RWLock' seems 
>>> to make much more sense... And there may even be a better term from 
>>> a CS textbook.
>>>
>>>
>>
>>
>
>
>
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp





From Haranath.Varanasi@scada.cmcltd.com Mon Feb 04 23:29:59 2002
Received: from [196.12.38.85] (helo=scada.cmcltd.com)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16Xx9u-0000GY-00
	for <bug-commoncpp@gnu.org>; Mon, 04 Feb 2002 23:24:51 -0500
Received: from localhost (haranath@localhost)
	by scada.cmcltd.com (8.11.2/8.8.7) with ESMTP id g154Lu510949
	for <bug-commoncpp@gnu.org>; Tue, 5 Feb 2002 09:51:57 +0530
Date: Tue, 5 Feb 2002 09:51:56 +0530 (IST)
From: <Haranath.Varanasi@scada.cmcltd.com>
To: <bug-commoncpp@gnu.org>
Subject: i am unable to compile CommonC++ on Tru64 unix 4.0f
In-Reply-To: <E16XmWE-0004AC-00@fencepost.gnu.org>
Message-ID: <Pine.LNX.4.33.0202050937410.10342-100000@scada.cmcltd.com>
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/>

hello
i am unable to build CommonC++ on Tru64 unix 4.0f .
i am useing gcc 2.95 and gnu make.

here is  make output
Making all in src
make[1]: Entering directory `/bkup/windows/hari/CommonC++-1.9.3/src'
/bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I. -I../src
-I/usr/local/include  -I../src  -g -O2 -D_GNU_SOURCE -D_REENTRANT
-D_THREAD_
SAFE -c thread.cpp
rm -f .libs/thread.lo
c++ -DHAVE_CONFIG_H -I. -I. -I. -I../src -I/usr/local/include -I../src -g
-O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -c thread.cpp  -DPIC -o
.libs/thr
ead.lo
In file included from config.h:406,
                 from thread.cpp:41:
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:984:
`valid' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:985:
`reserved' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:985:
cannot initialize arrays using this syntax
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:997:
`valid' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:998:
`name' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:998:
declaration of `char * __pthread_paddock_t::_Pfield'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:997:
conflicts with previous declaration `__pthreadLongUint_t
__pthread_paddock_t::_Pf
ield'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:999:
`arg' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:999:
declaration of `__pthreadLongUint_t __pthread_paddock_t::_Pfield'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:997:
conflicts with previous declaration `__pthreadLongUint_t
__pthread_paddock_t::_Pf
ield'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1000:
`reserved' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1000:
conflicting types for `long unsigned int _Pfield[19]'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:985:
previous declaration as `long unsigned int _Pfield[15]'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1000:
cannot initialize arrays using this syntax
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:998:
duplicate member `__pthread_paddock_t::_Pfield'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:999:
duplicate member `__pthread_paddock_t::_Pfield'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1096:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1096:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1096:
typedef declaration includes an initializer
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1096:
typedef `__pthreadConstructorFunc_t' is initialized
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1098:
type specifier omitted for parameter
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1098:
type specifier omitted for parameter
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1152:
syntax error before `('
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1340:
`pthread_mutexattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1340:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1342:
`pthread_mutexattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1342:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1352:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1352:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1365:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1365:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1370:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1370:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1372:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1372:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1374:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1374:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1383:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1383:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1395:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1395:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1407:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1407:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1591:
`pthread_condattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1591:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1593:
`pthread_condattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1593:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1596:
`pthread_condattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1596:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1598:
parse error before `*'

/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1609:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1609:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1622:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1622:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1634:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1634:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1646:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1646:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1658:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1658:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1671:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1671:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1678:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1678:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1680:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1694:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1694:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1697:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1711:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1711:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1716:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1727:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1727:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1740:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1746:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1746:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1749:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1753:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1753:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1757:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1761:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1762:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1766:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1767:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1774:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1774:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1776:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1776:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1785:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1785:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1798:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1804:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1804:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1807:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1818:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1818:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1852:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1852:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1865:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1865:
warning: `__pthread_detach' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1889:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1889:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1889:
warning: `__pthread_equal' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1889:
initializer list being treated as compound expression
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1918:
`pthread_once_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1918:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1924:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1924:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1927:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1927:
warning: `pthread_key_delete' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1930:
`pthread_key_t' was not declared in this scope

/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1930:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1975:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1975:
warning: `__pthread_getspecific' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1988:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:1988:
parse error before `void'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2039:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2039:
warning: `__pthread_cancel' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2078:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2084:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2084:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2092:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2092:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2097:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2097:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2105:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2106:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2110:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2111:
parse error before `char'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2118:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2118:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2123:
`pthread_mutex_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2123:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2131:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2131:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2136:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2136:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2144:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2145:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2149:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2150:
parse error before `char'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2160:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2160:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2172:
`pthread_cond_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2172:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2236:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2236:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2244:
`pthread_attr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2244:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2255:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2263:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2266:
`pthread_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2266:
warning: `pthread_getsequence_np' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2291:
`pthread_key_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2291:
warning: `pthread_key_validate_np' initialized and declared `extern'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2315:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2319:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2323:
`pthread_mutexattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2323:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2327:
`pthread_mutexattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2327:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2331:
`pthread_mutexattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2331:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2333:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2337:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2337:
parse error before `,'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2340:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2340:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2342:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2342:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2344:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2344:
parse error before `)'

/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2344:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2346:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2346:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2348:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2348:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2350:
`pthread_rwlock_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2350:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2352:
`pthread_rwlockattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2352:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2354:
`pthread_rwlockattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2354:
parse error before `)'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2357:
parse error before `*'
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2359:
`pthread_rwlockattr_t' was not declared in this scope
/usr/local/lib/gcc-lib/alphaev6-dec-osf4.0f/2.95/include/pthread.h:2359:
parse error before `,'
In file included from /usr/include/semaphore.h:45,
                 from config.h:412,
                 from thread.cpp:41:
/usr/include/sys/psx4_nspace_ts.h:68: `SEM_NAME_MAX' was not declared in
this scope
/usr/include/sys/psx4_nspace_ts.h:147: syntax error before `;'
/usr/include/sys/psx4_nspace_ts.h:149: syntax error before `;'
In file included from config.h:412,
                 from thread.cpp:41:
/usr/include/semaphore.h:66: `SEM_NAME_MAX' was not declared in this scope
In file included from config.h:538,
                 from thread.cpp:41:
/usr/include/sys/socket.h:203: syntax error before `;'
In file included from config.h:548,
                 from thread.cpp:41:
/usr/include/arpa/inet.h:71: syntax error before `('
/usr/include/arpa/inet.h:73: syntax error before `('
/usr/include/arpa/inet.h:74: `in_addr_t' was not declared in this scope
/usr/include/arpa/inet.h:74: `in_addr_t' was not declared in this scope
/usr/include/arpa/inet.h:74: warning: `inet_makeaddr' initialized and
declared `extern'
/usr/include/arpa/inet.h:75: syntax error before `('
/usr/include/arpa/inet.h:76: syntax error before `('
In file included from config.h:549,
                 from thread.cpp:41:
/usr/include/netdb.h:115: syntax error before `;'
In file included from config.h:552,
                 from thread.cpp:41:
/usr/include/netinet/in_systm.h:78: syntax error before `;'
/usr/include/netinet/in_systm.h:79: syntax error before `;'
/usr/include/netinet/in_systm.h:81: syntax error before `;'
In file included from config.h:555,
                 from thread.cpp:41:
/usr/include/netinet/ip.h:98: syntax error before `;'
/usr/include/netinet/ip.h:109: syntax error before `;'
/usr/include/netinet/ip.h:110: syntax error before `;'
/usr/include/netinet/ip.h:111: syntax error before `;'
/usr/include/netinet/ip.h:112: syntax error before `;'
/usr/include/netinet/ip.h:115: syntax error before `;'
/usr/include/netinet/ip.h:116: syntax error before `;'
/usr/include/netinet/ip.h:117: syntax error before `;'
/usr/include/netinet/ip.h:180: syntax error before `;'
/usr/include/netinet/ip.h:181: syntax error before `;'
/usr/include/netinet/ip.h:182: syntax error before `;'
/usr/include/netinet/ip.h:184: syntax error before `;'
/usr/include/netinet/ip.h:196: syntax error before `['
/usr/include/netinet/ip.h:199: syntax error before `;'
In file included from thread.cpp:43:
strchar.h: In method `int ost::keystring::compare(const char *)':

strchar.h:84: implicit declaration of function `int ost::strcasecmp(...)'
In file included from thread.cpp:45:
thread.h: At top level:
thread.h:85: syntax error before `;'
thread.h:236: syntax error before `;'
thread.h:339: syntax error before `;'
thread.h:503: syntax error before `;'
thread.h:651: syntax error before `;'
thread.h:1024: syntax error before `;'
thread.h:1025: syntax error before `;'
thread.h: In function `static void
ost::PosixThread::SignalThread(ost::Thread *, int)':
thread.h:1380: `class ost::Thread' has no member named `_tid'
thread.h:1380: implicit declaration of function `int
ost::pthread_kill(...)'
thread.h: At top level:
thread.h:1524: syntax error before `;'
thread.cpp: In method `void ost::Thread::Suspend()':
thread.cpp:94: `_tid' undeclared (first use this function)
thread.cpp:94: (Each undeclared identifier is reported only once
thread.cpp:94: for each function it appears in.)
thread.cpp: In function `void ost::ccxx_sigsuspend(int)':
thread.cpp:128: implicit declaration of function `int ost::sigwait(...)'
thread.cpp: In method `ost::Thread::Thread(bool)':
thread.cpp:183: implicit declaration of function `int
ost::__pthread_self(...)'
thread.cpp:196: assignment to `void (*)()' from `void (*)(int)'
thread.cpp:214: assignment to `void (*)()' from `void (*)(int)'
thread.cpp: In method `ost::Thread::Thread(int = 0, long unsigned int =
0)':
thread.cpp:248: `_attr' undeclared (first use this function)
thread.cpp: In method `ost::Thread::Thread(const ost::Thread &)':
thread.cpp:334: implicit declaration of function `int
ost::pthread_sigmask(...)'
thread.cpp: In method `int ost::Thread::Detach(ost::Semaphore * = 0)':
thread.cpp:377: `__pthread_detach' cannot be used as a function
thread.cpp:391: `__pthread_detach' cannot be used as a function
thread.cpp: In method `void ost::Thread::Terminate()':
thread.cpp:409: `__pthread_cancel' cannot be used as a function
thread.cpp: In function `void ost::execHandler(ost::Thread *)':
thread.cpp:426: `class ost::Thread' has no member named `_tid'
thread.cpp:452: `class ost::Thread' has no member named `_tid'
thread.cpp:452: `__pthread_detach' cannot be used as a function
thread.cpp:456: `class ost::Thread' has no member named `_tid'
thread.cpp: In method `void ost::Thread::Yield()':
thread.cpp:541: implicit declaration of function `int
ost::sched_yield(...)'
thread.cpp: In function `void ost::siginstall(int)':
thread.cpp:743: assignment to `void (*)()' from `void (*)(int)'
make[1]: *** [thread.lo] Error 1
make[1]: Leaving directory `/bkup/windows/hari/CommonC++-1.9.3/src'
make: *** [all-recursive] Error 1





From mail@cimaflex.com Tue Feb 05 05:40:00 2002
Received: from [211.106.130.90] (helo=pc4)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16Y315-0001C5-00
	for <bug-commoncpp@gnu.org>; Tue, 05 Feb 2002 05:40:00 -0500
Received: from pc4 ([211.106.130.90]) by pc4 with Microsoft SMTPSVC(5.0.2195.2966);
	 Tue, 5 Feb 2002 19:39:31 +0900
To:                    
From: mail@cimaflex.com
Subject: [성인광고]5,000원이면 한달이즐겁다(씨마플렉스영화관).
Date: Tue, 05 Feb 2002 19:39:31 +0900
Message-Id: <37292.819112511577300.510141@localhost>
MIME-Version: 1.0
Content-Type: text/html; charset=euc-kr
Content-Transfer-Encoding: 8bit
X-OriginalArrivalTime: 05 Feb 2002 10:39:31.0321 (UTC) FILETIME=[64F0AE90:01C1AE31]
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/>

<html>
<head>
<title> :: CIMA FLEX ::</title>
<meta name="generator" content="editplus">
<meta name="author" content="">
<meta name="keywords" content="">
<meta name="description" content="">



</head>

<body align=center valign=middle >

<table border="0" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF">
<tr><td><img src="http://www.zuzubatv.net/spam/cima_mail/empty.gif" height=20></td></tr>
<tr><td><img src="http://www.zuzubatv.net/spam/cima_mail/logo.gif" width="572" height="66" border=0 ></td></tr>
<tr><td><a href=http://www.cimaflex.com target=open2><img src="http://www.zuzubatv.net/spam/cima_mail/main.gif" width="572" height="249" border=0 ></a></td></tr>
<tr><td><a href=http://www.cimaflex.com target=open2><img src="http://www.zuzubatv.net/spam/cima_mail/text.gif"  width="572" height="356" border=0 ></a></td></tr><br>
<tr><td><img src="http://www.zuzubatv.net/spam/cima_mail/empty.gif"   height=6></td></tr>
<tr><td align= center><a href='http://www.zuzubatv.net/no_mail/'  target=open2 > <img src="http://www.zuzubatv.net/spam/cima_mail/button.gif" width="151" height="28"
border=0 ></a></td></tr>
</table>


</body>
</html>




From office7000@yahoo.co.kr Tue Feb 05 16:08:16 2002
Received: from [211.208.122.178] (helo=localhost)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16YCp5-00018h-00
	for <bug-commoncpp@gnu.org>; Tue, 05 Feb 2002 16:08:16 -0500
Reply-To: office7000@yahoo.co.kr
From: 성인정보<office7000@yahoo.co.kr>
To: bug-commoncpp@gnu.org
Subject: [광고] 어른들의 놀이동산 [미성년자는 제한합니다]
Mime-Version: 1.0
Content-Type: text/html; charset="ks_c_5601-1987"
Date: Wed, 6 Feb 2002 06:03:34 +0900
Message-Id: <E16YCp5-00018h-00@fencepost.gnu.org>
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/>

<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
<title> 귀하의 메일주소는 웹서핑중, http://www.xxxxxxxx.com/ </title>
<meta name="GENERATOR" content="Namo WebEditor v5.0">
<meta name="description" content="스타일이 전혀 적용되지 않은 새 문서 양식을 만듭니다.">
</head>
<body>

<table border="1" width="510">
    <tr>
        <td width="500">
            <p><img src="http://www.700office.com/img//7087073.bmp" width="500" height="449" border="0"></p>
        </td>
    </tr>
    <tr>
        <td width="500"><table border="1" cellspacing="0" width="499" bgcolor="white" bordercolordark="black" bordercolorlight="black">
    <tr>
        <td width="493"><p style="line-height:20px;" align="center"><SPAN style="FONT-SIZE: 9pt">귀하의 메일주소는 웹서핑중, <B>http://www.xxxxxxxx.com/</B> 
<BR>에서 알게 된것이며, E-Mail 주소 외에, 다른 정보는 갖고 있지 않습니다.<BR>정통부 권고사항에 의거 제목에 
</SPAN><B><SPAN style="FONT-SIZE: 9pt">[광고]</SPAN></B><SPAN style="FONT-SIZE: 9pt">라고 표기한 메일입니다.</SPAN><A 
href="mailto:office7000@yahoo.co.kr ?subject=수신거부" target=new><B><SPAN 
style="FONT-SIZE: 9pt"><FONT color=red>수신거부</FONT></SPAN></B></A><SPAN style="FONT-SIZE: 9pt">를 눌러주세요</SPAN> 
</p>
        </td>
    </tr>
</table>
        </td>
    </tr>
</table>
<p>&nbsp;</p>
</body>
</html>


From bigdan3330@lycos.com Tue Feb 05 23:48:21 2002
Received: from cl35-227.invision.com ([206.112.35.227] helo=cyber1.cybermedia.com)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16YK0G-0000XN-00; Tue, 05 Feb 2002 23:48:17 -0500
Received: from 24.223.17.98 [24.223.17.98] by cyber1.cybermedia.com
  (SMTPD32-6.00) id A54AC05B0196; Tue, 05 Feb 2002 23:47:06 -0500
Message-ID: <000071642689$00003f95$00001b75@>
To: <Undisclosed Recipients>
From: bigdan3330@lycos.com
Subject: Give Yourself a Pay Raise!
Date: Tue, 05 Feb 2002 21:47:41 -0700
MIME-Version: 1.0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
X-Priority: 3
X-MSMail-Priority: Normal
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/>

<HTML>
<BODY>

<FONT size=3D2> <meta http-equiv=3D"Content-Language" content=3D"en-us"><B=
R>
<p><b><font face=3D"Verdana">Dear Friend,</font></b></p><BR>
<p><font face=3D"Verdana">Have you ever thought about starting your own ho=
me <BR>
business from home?&nbsp; Here are some of the benefits of owning your own=
 <BR>
business.</font></p><BR>
<ul><BR>
  <li><b><font face=3D"Verdana">Extra Income!</font></b></li><BR>
  <li><b><font face=3D"Verdana">More time to spend with your friends and f=
amily!</font></b></li><BR>
  <li><b><font face=3D"Verdana">Better time/money relationship!</font></b>=
</li><BR>
  <li><b><font face=3D"Verdana">Become Your Own BOSS!</font></b></li><BR>
  <li><b><font face=3D"Verdana">Be stay at home parents!</font></b></li><B=
R>
  <li><b><font face=3D"Verdana">A tax write off for those already making b=
ig <BR>
  money!</font></b></li><BR>
</ul><BR>
<p><font face=3D"Verdana">These are just some of the benefits of owning an=
d <BR>
running your own business.</font></p><BR>
<p><font face=3D"Verdana">In case you didn't know<b> the internet is <u>HU=
GE</u>!&nbsp;<BR>
</b>It's going to keep growing with or without you.&nbsp; This is your cha=
nce to<BR>
<b>Grab the Bull by the Horns</b>!</font></p><BR>
<p><font face=3D"Verdana">I'm not asking you to jump at the first opportun=
ity that <BR>
comes your way.&nbsp; Opportunities are presented to us everyday.&nbsp; </=
font><BR>
</p><BR>
<p><font face=3D"Verdana">All I'm asking is you be <b>Open-Minded</b> and =
<BR>
recognize the opportunity that is being presented.&nbsp; Do your due dilig=
ence <BR>
and explore the idea of working from home.</font></p><BR>
<p><b><i><font face=3D"Verdana">For more information about working from ho=
me call:</font></i></b></p><BR>
<p><b><i><font face=3D"Verdana"><u>TOLL FREE</u> 1-888-445-8997</font></i>=
</b></p><BR>
<p><b><i><font face=3D"Verdana">I look forward to speaking to you soon.</f=
ont></i></b></p><BR>
<p><b><i><font face=3D"Verdana">Thanks and have a Great Day!</font></i></b=
></p><BR>
<p><b><i><font face=3D"Verdana">Philip</font></i></b></p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p>&nbsp;</p><BR>
<p align=3D"center"><font face=3D"Verdana" size=3D"1">If you would like to=
 be removed <BR>
from future e-mails then please reply with REMOVE in the subject line.</fo=
nt></p><BR>
<p>&nbsp;</p><BR>
<BR>
</FONT>
</BODY>
</HTML>




From jjn@kriln.com Wed Feb 06 02:49:28 2002
Received: from evrtwa1-ar1-181-212.evrtwa1.dsl.gtei.net ([4.3.181.212] helo=tremere.kriln.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16YMpb-0004vA-00
	for <bug-commoncpp@gnu.org>; Wed, 06 Feb 2002 02:49:27 -0500
Received: by tremere.kriln.com (Postfix, from userid 1000)
	id 01B5EA8901; Tue,  5 Feb 2002 23:46:42 -0800 (PST)
Received: from localhost (localhost [127.0.0.1])
	by tremere.kriln.com (Postfix) with ESMTP id E72C2A4B06
	for <bug-commoncpp@gnu.org>; Tue,  5 Feb 2002 23:46:42 -0800 (PST)
Date: Tue, 5 Feb 2002 23:46:42 -0800 (PST)
From: Jeremy Noetzelman <jjn@kriln.com>
To: <bug-commoncpp@gnu.org>
Subject: couple CommonC++ questions
Message-ID: <20020205232946.S31187-100000@tremere.kriln.com>
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'm working on a server application (FreeBSD 4.3, CommonC++ 1.9.5), using
a SocketService instantiation as well as a class derived from SocketPort
(call it mySocketPort)

--begin code

   SocketService * svc = new SocketService(0);
   InetHostAddr host("localhost);
   TCPSocket socket(host, 6275);

   mySocketPort* newConnection = NULL;

   while(1) {
      cerr << svc->getCount() << " clients are connected."
           << endl << flush;

      newConnection = new mySocketPort(svc, socket);
      newConnection->setCompletion(false);

      cerr << "connection accepted" << endl << flush;
   }

-- end code

After compiling and launching the application, as expected, cerr output
indicates that the service has 0 clients:

   0 clients are connected.

I then use telnet to connect to port 6275, and expect the service thread
to indicate that a client has connected.  Output verifies this:

   connection accepted
   1 clients are connected.

I then close that connection and reconnect.  I would expect normally for
the client count to decrement to 0, then increment to 1 again, with cerr
output indicating that the client count is again 1.  Instead, I get this:

   connection accepted
   2 clients are connected.

clearly, the service is not detaching clients properly as the client count
is not properly updated when a client disconnects.

I've enhanced mySocketPort to implement Disconnect().  Disconnect() simply
logs to cerr when it is called.  I also added a cerr log to the destructor
to track calls to it.

All works well while the first client is connected, but neither
Disconnect() or the destructor are called when the client disconnects.

Setting mySocketPort.setTimer() to a low value and waiting for it to
timeout calls my Expired() implementation properly.

I'm hoping someone can shed some light on this for me and explain why the
SocketService isn't detecting socket disconnections.

Thanks,

Jeremy Noetzelman



From psycho@tex.ro Wed Feb 06 08:05:31 2002
Received: from psychophobia.tex.ro ([213.154.142.82] helo=tex.ro)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16YRlR-0006Qx-00
	for <bug-commoncpp@gnu.org>; Wed, 06 Feb 2002 08:05:30 -0500
Received: from PerfectSense ([192.168.1.111])
	by tex.ro (8.11.0/8.11.0) with SMTP id g16GGRL04208
	for <bug-commoncpp@gnu.org>; Wed, 6 Feb 2002 18:16:28 +0200
Message-ID: <001401c1af0f$aa8815e0$0103a8c0@PerfectSense>
From: "Vladimir Ciobanu" <psycho@tex.ro>
To: <bug-commoncpp@gnu.org>
Subject: Re: Problem with commonc++-??? and gcc-3.0.3
Date: Wed, 6 Feb 2002 15:10:35 +0200
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 6.00.2462.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2462.0000
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 just installed gcc-3.0.3 and I've got some errors with commomc++-1.9.5
 presented at the end of the email. I am wondering whether I am doing
something wrong or is it a known problem with that current commomc++
package. Are they any patches which would make it compile with gcc-3.0.3 or
is it going to be supported in later packages ? Any answer will be
apreciated.

/bin/sh ../libtool --mode=compile
-DHAVE_CONFIG_H -I. -I. -I. -I../src     -
I../src  -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -c exception.cpp
rm -f .libs/exception.lo
c++ -DHAVE_CONFIG_H -I. -I. -I. -I../src -I../src -g -O2 -D_GNU_SOURCE -D_RE
ENTR
ANT -D_THREAD_SAFE -c exception.cpp  -fPIC -DPIC -o
.libs/exception.lo
exception.cpp:50: syntax error before `::' token
exception.cpp:54: syntax error before `::' token
exception.cpp:57: syntax error before `::' token
exception.cpp:64: syntax error before `::' token
exception.cpp:68: syntax error before `::' token
make[1]: *** [exception.lo] Error 1
make[1]: Leaving directory `/var/ftp/pub/linux/libs/CommonC++-1.9.5/src'
make: *** [all-recursive] Error 1

Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.0.3/specs
Configured with:
../gcc-3.0.3/configure --enable-languages=c,c++ --enable-threads
Thread model: posix
gcc version 3.0.3

  Thank you

PS: I'm sending this email again since I am not sure I sent it properly the
first time. I appologise if you see this for the second time. Any reply
would be appreciated.



From acidrain113@hotmail.com Thu Feb 07 13:59:20 2002
Received: from mail.spamwhack.com ([204.95.210.9])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16YtlQ-0005Xn-00
	for <bug-commoncpp@gnu.org>; Thu, 07 Feb 2002 13:59:20 -0500
Received: (qmail 25573 invoked by uid 0); 7 Feb 2002 18:35:21 -0000
Received: from localhost (HELO 24.223.17.39) (sendmail-bs@127.0.0.1)
  by localhost with SMTP; 7 Feb 2002 18:35:21 -0000
Message-ID: <0000264d5bf9$00001dcb$000064bc@>
To: <Undisclosed Recipients>
From: acidrain113@hotmail.com
Subject: Residual뀉꿌s for Life!  Let us prove it!
Date: Thu, 07 Feb 2002 11:37:31 -0700
MIME-Version: 1.0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
X-Priority: 3
X-MSMail-Priority: Normal
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/>

<HTML>
<BODY>

<FONT size=3D2> Dear Friend,  You are about to discover how you can start =
 your very own Home Based Business working in two of the fastest growing i=
ndustries in America.  But first, please let me introduce myself...  My na=
me is Philip.  I'd like for you to know up front that I'm not an Internet =
Guru......Not A Computer Wiz.....And Not a Marketing Genius.  First of all=
 let me say this.  I don't expect you to believe a single word I say.  Aft=
er all, how many times a day are you BOMBARDED with some lame "get rich qu=
ick" scheme on the Internet?  You probably get a brand new promise of Inst=
ant Wealth every few hours in your e-mail box and if you are anything like=
 me, you have tried a few and been left with nothing but a big hole in you=
r pocket!  Well, I've got great news for you!  Now you too can make great =
money right from your home with a company that has a 6 year proven track r=
ecord of success.  In our business "Our Reps Come First."  You Can Do It T=
oo..... But I'm not going to sit here and tell you that I'll make you rich=
..or that you'll make gobs of cash just sitting on your couch doing nothi=
ng.  Why would anyone want to insult your intelligence like that?  I will =
tell you however, that you can cash in on your share of all the money that=
's being made out there on the Internet.  Let me show you how.  In fact, I=
'm willing and want to help you personally.  Now I'm not asking you to jum=
p on the first opportunity that comes your way.  All I'm asking is that yo=
u get the facts needed to make an educated and informed decision about you=
r future.  Do you due diligence and get your questions answered.  That's w=
hat I am here for.  Here's how.  Call my toll free number.  Leave me your =
Name, Number including are code, and the best time to call.  I will person=
ally return your phone call and walk you through a simple system to get yo=
ur questions answered.  I look forward to you call and am anxious to work =
with you. Call Me Right Now Toll Free! 1-888-445-8997    If you would like=
 to be removed from future e-mails.  Please reply with REMOVE in subject l=
ine.<BR>
<BR>
</FONT>
</BODY>
</HTML>




From anand_narwani@yahoo.com Fri Feb 08 14:16:44 2002
Received: from web12301.mail.yahoo.com ([216.136.173.99])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16ZGVo-0006u4-00
	for <bug-commoncpp@gnu.org>; Fri, 08 Feb 2002 14:16:44 -0500
Message-ID: <20020208191643.16018.qmail@web12301.mail.yahoo.com>
Received: from [24.93.64.110] by web12301.mail.yahoo.com via HTTP; Fri, 08 Feb 2002 11:16:43 PST
Date: Fri, 8 Feb 2002 11:16:43 -0800 (PST)
From: Anand Narwani <anand_narwani@yahoo.com>
Subject: Binding to source address for client connections
To: bug-commoncpp@gnu.org
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/>

Hello,
I have a requirement to be able to bind a URLStream to
a source interface when making connections to remote
servers.  This allows me to control the source address
used for the TCP session. 
I have since modified the URLStream class to allow me
to do this.  Essentially, I modified the
sendHTTPHeaders method to bind to a source interface
if it has been set.  
Are there any plans to include a feature of this kind
into the main releases?

Thanks in advance,
Anand Narwani

__________________________________________________
Do You Yahoo!?
Send FREE Valentine eCards with Yahoo! Greetings!
http://greetings.yahoo.com


From dyfet@ostel.com Fri Feb 08 14:34:06 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16ZGmb-0000tq-00
	for <bug-commoncpp@gnu.org>; Fri, 08 Feb 2002 14:34:06 -0500
Received: by home.sys (Postfix, from userid 501)
	id CE5A8301F6; Fri,  8 Feb 2002 14:48:58 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id C830529284; Fri,  8 Feb 2002 14:48:58 -0500 (EST)
Date: Fri, 8 Feb 2002 14:48:58 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: Anand Narwani <anand_narwani@yahoo.com>
Cc: <bug-commoncpp@gnu.org>
Subject: Re: Binding to source address for client connections
In-Reply-To: <20020208191643.16018.qmail@web12301.mail.yahoo.com>
Message-ID: <Pine.LNX.4.33L2.0202081448300.5259-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/>

If you would like to submit a patch for this, I would be happy to look at
it and possibly include it...

David

On Fri, 8 Feb 2002, Anand Narwani wrote:

> Hello,
> I have a requirement to be able to bind a URLStream to
> a source interface when making connections to remote
> servers.  This allows me to control the source address
> used for the TCP session.
> I have since modified the URLStream class to allow me
> to do this.  Essentially, I modified the
> sendHTTPHeaders method to bind to a source interface
> if it has been set.
> Are there any plans to include a feature of this kind
> into the main releases?
>
> Thanks in advance,
> Anand Narwani
>
> __________________________________________________
> Do You Yahoo!?
> Send FREE Valentine eCards with Yahoo! Greetings!
> http://greetings.yahoo.com
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>



From anand_narwani@yahoo.com Fri Feb 08 17:04:56 2002
Received: from web12304.mail.yahoo.com ([216.136.173.102])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16ZJ8a-0003HJ-00
	for <bug-commoncpp@gnu.org>; Fri, 08 Feb 2002 17:04:56 -0500
Message-ID: <20020208220455.15867.qmail@web12304.mail.yahoo.com>
Received: from [24.93.64.110] by web12304.mail.yahoo.com via HTTP; Fri, 08 Feb 2002 14:04:55 PST
Date: Fri, 8 Feb 2002 14:04:55 -0800 (PST)
From: Anand Narwani <anand_narwani@yahoo.com>
Subject: Re: Binding to source address for client connections
To: David Sugar <dyfet@ostel.com>
Cc: bug-commoncpp@gnu.org
In-Reply-To: <Pine.LNX.4.33L2.0202081448300.5259-100000@home>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="0-1687154014-1013205895=:15844"
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/>

--0-1687154014-1013205895=:15844
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

David,
I have attached the patches to this email.  Please let
me know if I need to resend as plain text in an email.

Anand
--- David Sugar <dyfet@ostel.com> wrote:
> 
> If you would like to submit a patch for this, I
> would be happy to look at
> it and possibly include it...
> 
> David
> 
> On Fri, 8 Feb 2002, Anand Narwani wrote:
> 
> > Hello,
> > I have a requirement to be able to bind a
> URLStream to
> > a source interface when making connections to
> remote
> > servers.  This allows me to control the source
> address
> > used for the TCP session.
> > I have since modified the URLStream class to allow
> me
> > to do this.  Essentially, I modified the
> > sendHTTPHeaders method to bind to a source
> interface
> > if it has been set.
> > Are there any plans to include a feature of this
> kind
> > into the main releases?
> >
> > Thanks in advance,
> > Anand Narwani
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Send FREE Valentine eCards with Yahoo! Greetings!
> > http://greetings.yahoo.com
> >
> > _______________________________________________
> > Bug-commoncpp mailing list
> > Bug-commoncpp@gnu.org
> > http://mail.gnu.org/mailman/listinfo/bug-commoncpp
> >
> 


__________________________________________________
Do You Yahoo!?
Send FREE Valentine eCards with Yahoo! Greetings!
http://greetings.yahoo.com
--0-1687154014-1013205895=:15844
Content-Type: text/plain; name="url.cpp.patch"
Content-Description: url.cpp.patch
Content-Disposition: inline; filename="url.cpp.patch"

--- posix/url.cpp	Mon Oct 29 07:31:18 2001
+++ posix/url.cpp	Thu Feb  7 15:16:34 2002
@@ -72,6 +72,7 @@
 	encoding = URL_BINARY_ENCODING;
 	auth = URL_ANONYMOUS_AUTH;
 	cookie = agent = pragma = referer = user = password = NULL;
+	localif = NULL;
 	setError(false);
 }
 
@@ -253,6 +254,7 @@
 	if(Socket::state != SOCKET_AVAILABLE)
 		Close();
 
+	
 	if(!strnicmp(path, "file:", 5))
 	{
 		urlmethod = FILE_GET_METHOD;
@@ -479,6 +481,33 @@
 
         if(Socket::state != SOCKET_AVAILABLE)
                         Close();
+	if (localif != NULL) {
+		struct ifreq ifr;
+		int alen = sizeof(source);
+
+		memset(&ifr, 0, sizeof(ifr));
+		strncpy(ifr.ifr_name, localif, 15);
+		if (ioctl(so, SIOCGIFINDEX, &ifr) < 0) {
+			cerr << "Warning Unknown interface!" << endl;
+		} else {
+			if (setsockopt(so, 
+				SOL_SOCKET, 
+				SO_BINDTODEVICE, 
+				&ifr,
+				sizeof(ifr)) == -1) {
+					cerr << "Ignoring Interface!" <<endl;
+			} else if (getsockname(so, (struct sockaddr*)&source,(socklen_t *) &alen) == -1) {
+				cerr << "getsockname error!" << endl;
+			} else if (bind(so, (struct sockaddr*)&source, sizeof(source)) == -1) {
+					cerr << "Bind Error!" << endl;
+			} else {
+					source.sin_port = 0;
+			}
+			
+
+		}
+
+	}
 
 	if(proxyPort)
 	        Connect(proxyHost, proxyPort, bufsize);

--0-1687154014-1013205895=:15844
Content-Type: text/plain; name="url.h.patch"
Content-Description: url.h.patch
Content-Disposition: inline; filename="url.h.patch"

--- posix/url.h	Thu Oct  4 15:28:22 2001
+++ posix/url.h	Fri Feb  1 08:00:43 2002
@@ -44,6 +44,8 @@
 #ifndef __CCXX_SOCKET_H__
 #include <cc++/socket.h>
 #endif
+#include <net/if.h>
+#include <sys/ioctl.h>
 
 typedef enum
 {
@@ -100,6 +102,8 @@
 {
 private:
 	const char *agent, *referer, *cookie, *pragma, *user, *password;
+	const char *localif;
+	InetHostAddress localAddr;
 	InetHostAddress proxyHost, prevHost;
 	tpport_t proxyPort, prevPort;
 	InetHostAddress refhost;
@@ -112,6 +116,7 @@
 	bool follow;
 	unsigned chunk;
 	char authbuf[128];
+	struct sockaddr_in source;
 
 	urlerror_t getHTTPHeaders(char *buffer, unsigned bufsize);
 
@@ -282,6 +287,13 @@
 	 */
 	inline void setProtocol(urlprotocol_t pro)
 		{protocol = pro;};
+	/**
+	 * Specify local interface to use
+	 *
+	 * @param Local interface name
+	 */
+	inline void setLocalInterface(const char *intf) 
+	{localif=intf;} 
 };
 
 extern __EXPORT char *urldecode(char *source, char *dest = NULL);

--0-1687154014-1013205895=:15844--


From arjan.paijralbe@bluewin.ch Sun Feb 10 10:23:21 2002
Received: from mta1n.bluewin.ch ([195.186.1.210])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16Zvp2-0006Bu-00
	for <bug-commoncpp@gnu.org>; Sun, 10 Feb 2002 10:23:20 -0500
Received: from bluewin.ch (213.3.203.3) by mta1n.bluewin.ch (Bluewin AG 6.0.040)
        id 3C5F86FA001CD917 for bug-commoncpp@gnu.org; Sun, 10 Feb 2002 16:23:19 +0100
Message-ID: <3C669395.2040704@bluewin.ch>
Date: Sun, 10 Feb 2002 16:36:53 +0100
From: arjan derk-jan paijralbe <arjan.paijralbe@bluewin.ch>
User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:0.9.6+) Gecko/20011130
X-Accept-Language: en-us
MIME-Version: 1.0
To: bug-commoncpp@gnu.org
Subject: New Class for the library
Content-Type: multipart/mixed;
 boundary="------------000701060908070904000307"
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.
--------------000701060908070904000307
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

Hi
A good library, so I've a new class for it.
It is a string class to handle urls's.
I've also add an entry for doxygen to doc global functions.

kind regards
   arjan

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

// 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 "url_string.h"
#include <cstdlib>
#include <stdlib.h>

#ifdef  CCXX_NAMESPACES
namespace ost {
#endif


//*****************************************************************************
static char *hex_char = "0123456789abcdef";

//*****************************************************************************
UrlString::UrlString( urlcode_t _urlcode )
          :string(), urlcode(_urlcode), check(1)
{
}

//*****************************************************************************
UrlString::UrlString( char *url, urlcode_t _urlcode )
          :string( url ), urlcode(_urlcode), check(1)
{
}

//*****************************************************************************
UrlString::UrlString( string &url, urlcode_t _urlcode )
          :string( url ), urlcode(_urlcode), check(1)
{
}

//*****************************************************************************
UrlString::UrlString( UrlString &url )
          :string( url ), urlcode(url.urlcode), check(1)
{
}

//*****************************************************************************
UrlString::UrlString( InetAddress &address, urlcode_t urlcode )
               :string(), urlcode(urlcode), check(1)
{
   SetUrl( address );
}

//*****************************************************************************
UrlString::~UrlString( void )
{

}

//*****************************************************************************
UrlString& UrlString::operator=( char *url )
{
   return assign( url );
}

//*****************************************************************************
UrlString& UrlString::operator=( UrlString &url )
{
   return assign( url );
}

//*****************************************************************************
UrlString& UrlString::operator=( string &url )
{
   return assign( url );
}

//*****************************************************************************
UrlString& UrlString::operator=( urlcode_t _urlcode )
{
   urlcode = _urlcode;
   return *this;
}

//*****************************************************************************
bool UrlString::operator==( UrlString &url )
{
   findpos();
   url.findpos();

   return !Cmp( (int)url_begin, url_end - url_begin,
                   url, (int)url.url_begin, url.url_end - url.url_begin ) &&
          !Cmp( (int)path_begin, path_end - path_begin,
                url, (int)url.path_begin, url.path_end - url.path_begin ) &&
                  (GetPort() == url.GetPort());
}


//*****************************************************************************
bool UrlString::operator>( UrlString &url )
{
   int result;
   findpos();
   url.findpos();

   result = Cmp( url_begin, url_end - url_begin,
                          url, url.url_begin, url.url_end - url.url_begin );
   if( result == 0 )
   {
      return (Cmp( path_begin, path_end - path_begin,
                 url, url.path_begin, url.path_end - url.path_begin ) > 0 );
   }
   return (result > 0);
}

//*****************************************************************************
bool UrlString::operator<( UrlString &url )
{
   int result;
   findpos();
   url.findpos();

   result = Cmp( url_begin, url_end - url_begin,
                          url, url.url_begin, url.url_end - url.url_begin );
   if( result == 0 )
   {
      return (Cmp( path_begin, path_end - path_begin,
                 url, url.path_begin, url.path_end - url.path_begin ) < 0 );
   }
   return (result < 0);
}


//*****************************************************************************
UrlString& UrlString::assign( char *url )
{
   check = 1;
   string::assign( url );
   return *this;
}

//*****************************************************************************
UrlString& UrlString::assign( UrlString &url )
{
   check = 1;
   string::assign( url );
   return *this;
}

//*****************************************************************************
UrlString& UrlString::assign( string &url )
{
   check = 1;
   string::assign( url );
   return *this;
}

//*****************************************************************************
char *UrlString::GetService( char *buffer, size_t size )
{
   findpos( );
   if( buffer && ( service_end < size ))
   {
      if( service_end > 0 )
      {
         copy( buffer, service_end, 0 );
         buffer[service_end] = '\0';
      }
      else
      {
         buffer[0] = '\0';
      }
      return buffer;
   }
   return NULL;
}

//*****************************************************************************
string UrlString::GetService( void )
{
   findpos( );
   if( service_end > 0 )
   {
      return string( *this, 0, service_end );
   }
   else
   {
      return string();
   }
}

//*****************************************************************************
void UrlString::SetService( char *service )
{
   if( service )
   {
      findpos( );

      if( service_end > 0 )
      {
         replace( 0, service_end, service );
      }
      else
      {
         insert( 0, "://" );
         insert( 0, service );
      }
      check = 1;
   }
}

//*****************************************************************************
void UrlString::SetService( UrlString &service )
{
   service.findpos( );
   findpos( );

   if( service.service_end > 0 )
   {
      if( service_end > 0 )
      {
         replace( 0, service_end, service, 0, service.service_end );
      }
      else
      {
         insert( 0, "://" );
         insert( 0, service, 0, service.service_end );
      }
      check = 1;
   }
}


//*****************************************************************************
char *UrlString::GetPath( char *buffer, size_t size )
{
   int copy_size;

   findpos( );
   copy_size = path_end - path_begin;

   if( buffer && ( size > copy_size ) && ( size > 2 ))
   {
      if( path_begin < path_end )
      {
         copy_size = UrlDecode((char*)string::c_str() + path_begin,
                                                     copy_size, buffer, size );
         if( copy_size >= 0 )
         {
            buffer[copy_size] = '\0';
         }
         else
         {
            return NULL;
         }
      }
      else
      {
         strcpy( buffer, "/" );
      }
      return buffer;
   }
   return NULL;
}

//*****************************************************************************
string UrlString::GetPath( void )
{
   findpos( );

   if( path_begin < path_end )
   {
      string temp;
      temp = string( *this, path_begin, path_end - path_begin );
      UrlDecode_s( temp );
      return temp;
   }
   else
   {
      return string( "/" );
   }
}

//*****************************************************************************
void UrlString::SetPath( char *path )
{
   if( path )
   {
      findpos( );

      if( path_begin < path_end )
      {
         if( *path != '/' )
         {
            path_begin++;
         }
         replace( path_begin, path_end - path_begin, path );
      }
      else
      {
         if( *path != '/' )
         {
            insert( path_begin, "/" );
            path_begin++;
         }
         insert( path_begin, path );
      }
      check = 1;
   }
}

//*****************************************************************************
void UrlString::SetPath( UrlString &path )
{
   unsigned int size, path_size;
   findpos( );
   path.findpos( );

   size = path_end - path_begin;
   path_size = path.path_end - path.path_begin;

   if( size > 0 )
   {
      if( path_size > 0)
      {
         replace( path_begin, size, path, path.path_begin, path_size );
      }
      else
      {
         replace( path_begin, size, "/" );
      }
   }
   else
   {
      if( path_size > 0)
      {
         insert( path_begin, path, path.path_begin, path_size );
      }
      else
      {
         insert( path_begin, "/" );
      }
   }
   check = 1;
}


//*****************************************************************************
char *UrlString::GetUrl( char *buffer, size_t size )
{
   unsigned int copy_size;

   findpos( );
   copy_size = url_end - url_begin;

   if( buffer && ( size > copy_size ) && size)
   {
      if( url_begin < url_end )
      {
         copy( buffer, copy_size, url_begin );
         buffer[copy_size] = '\0';
      }
      else
      {
         buffer[0] = '\0';
      }
      return buffer;
   }
   return NULL;
}

//*****************************************************************************
string UrlString::GetUrl( void )
{
   findpos( );
   if( url_begin < url_end )
   {
      return string( *this, url_begin, url_end - url_begin );
   }
   else
   {
      return string();
   }
}


//*****************************************************************************
void UrlString::SetUrl( char *url )
{
   if( url )
   {
      findpos( );

      if( url_begin < url_end )
      {
         replace( url_begin, url_end - url_begin, url );
      }
      else
      {
         insert( url_begin, url );
      }
      check = 1;
   }
}


//*****************************************************************************
void UrlString::SetUrl( UrlString &url )
{
   unsigned int size, url_size;
   findpos( );
   url.findpos( );

   size = url_end - url_begin;
   url_size = url.url_end - url.url_begin;

   findpos( );
   url.findpos( );

   if( url_size > 0 )
   {
      if( size > 0 )
      {
         replace( url_begin, size, url, url.url_begin, url_size );
      }
      else
      {
         insert( url_begin, url, url.url_begin, url_size );
      }
      check = 1;
   }
}

//*****************************************************************************
void UrlString::SetUrl( InetAddress &address )
{
   // A valid address ?
   if( address.isInetAddress() )
   {
      SetUrl( (char*)address.getHostname() );
   }
}



//*****************************************************************************
InetAddress &UrlString::GetAdresss( InetAddress &address )
{
   char *buffer;
   unsigned int copy_size;

   findpos( );

   copy_size = (url_end - url_begin)  + 1;

   if( url_begin < url_end )
   {
      buffer = new char[copy_size];

      copy( buffer, copy_size, url_begin );
      buffer[copy_size] = '\0';
      address = (const char*)buffer;

      delete[] buffer;
   }
   else
   {
      address = (unsigned long)0;
   }
   return address;
}


//*****************************************************************************
char *UrlString::GetUser( char *buffer, size_t size )
{
   unsigned int copy_size;

   findpos( );
   copy_size = path_end - path_begin;

   if( buffer && ( size > copy_size ) && ( size > 2 ))
   {
      if( user_begin < user_end )
      {
         copy( buffer, copy_size, user_begin );
         buffer[copy_size] = '\0';
      }
      else
      {
         buffer[0] = '\0';
      }
      return buffer;
   }
   return NULL;
}

//*****************************************************************************
string UrlString::GetUser( void )
{
   findpos( );
   if( user_begin < user_end )
   {
      return string( *this, user_begin, user_end - user_begin);
   }
   else
   {
      return string( );
   }
}

//*****************************************************************************
int UrlString::SetUser( char *user )
{
   if( user )
   {
      findpos( );

      // Only posible if there is a url.
      if( url_begin < url_end )
      {
         if( user_begin < user_end )
         {
            replace( user_begin, user_end - user_begin, user );
         }
         else
         {
            insert( user_begin, "@" );
            insert( user_begin, user );
         }
         check = 1;
         return 0;
      }
   }
   return -1;
}


//*****************************************************************************
int UrlString::SetUser( UrlString &user )
{
   unsigned int size, user_size;

   findpos( );
   user.findpos( );

   size =  user_end - user_begin;
   user_size=  user.user_end - user.user_begin;

   // Only posible if there is a url.
   if( url_begin < url_end )
   {
      if( user_size > 0 )
      {
         if( size > 0 )
         {
            replace( user_begin, size, user, user.user_begin, user_size );
         }
         else
         {
            insert( user_begin, user, user.user_begin, user_size + 1 );
         }
      }
      check = 1;
   }
}

//*****************************************************************************
void UrlString::EraseUser( void )
{
   findpos( );
   if( user_begin < user_end )
   {
      erase( user_begin, user_end + 1 );
   }
}

//*****************************************************************************
char *UrlString::GetQuery( char *buffer, size_t size )
{
   unsigned int copy_size;
   int end;

   findpos( );
   end = string::size();
   copy_size = end - path_end;

   if( buffer && ( size > copy_size ) && size )
   {
      if( path_end < end )
      {
         copy_size--;
         copy( buffer, copy_size, path_end + 1 );
         buffer[copy_size] = '\0';
      }
      else
      {
         buffer[0] = '\0';
      }
      return buffer;
   }
   return NULL;
}

//*****************************************************************************
string UrlString::GetQuery( void )
{
   int end;
   findpos( );

   end = size() - 1;
   if( path_end < end )
   {
      return string( *this, path_end + 1, end - path_end );
   }
   else
   {
      return string( );
   }
}

//*****************************************************************************
int UrlString::SetQuery( char *query )
{
   if( query && !prepeare_for_query( ) )
   {
      if( *query == '?' )
      {
         query++;
      }
      replace( path_end + 1, size() - path_end - 1, query );

      return 0;
   }
   return -1;
}


//*****************************************************************************
int UrlString::SetQuery( UrlString &query )
{
   unsigned int query_size;

   query.findpos( );
   query_size = query.size() - query.path_end;

   if( query_size > 0 )
   {
      if( !prepeare_for_query( ) )
      {
         replace( path_end, size() - path_end, query, query.path_end, query_size );
      }
      return 0;
   }
   return -1;
}

//*****************************************************************************
void UrlString::EraseQuery( void )
{
   int end;

   findpos( );

   end = size();

   if( path_end < end )
   {
      erase( path_end, end );
      check = 1;
   }
}

//*****************************************************************************
void UrlString::AddQuery( char* entry, char * value )
{
   char *buffer;
   int b_size, e_size, v_size = 0;

   if( !prepeare_for_query( ) && entry )
   {
      e_size = strlen( entry );
      b_size = e_size;
      if( value )
      {
         v_size = strlen( value );
      }
      if( e_size < v_size )
      {
         b_size = v_size;
      }
      b_size *= 3;
      buffer = new char[b_size];
      UrlEncode(entry, e_size, buffer, b_size );
      if( *rbegin() != '?' )
      {
         append("+");
      }
      append(buffer);
      if( value )
      {
         append("=");
         UrlEncode(value, v_size, buffer, b_size );
         append(buffer);
      }
      delete[] buffer;
   }
}

//*****************************************************************************
int UrlString::FirstQuery( char* entry, size_t e_size,
                                                 char * value, size_t v_size )
{
   findpos( );
   if( path_end < size() )
   {
      query = path_end;
      return NextQuery( entry, e_size, value, v_size );
   }
   return -1;
}

//*****************************************************************************
int UrlString::NextQuery( char* entry, size_t e_size,
                                                 char* value, size_t v_size )
{
   int entry_start, entry_end, value_start, value_end;
   char *start;
   findpos( );
   if( !next_query_pos( entry_start, entry_end, value_start, value_end ) )
   {
      start = (char*)string::c_str();
      if( entry && UrlDecode( start + entry_start,
                                entry_end - entry_start, entry, e_size ) >= 0 )
      {
         if( value && ( value_start < value_end ) &&
            ( UrlDecode( start + value_start,
                               value_end - value_start, value, v_size ) >= 0 ))
         {
            return 0;
         }
         else
         {
            *value = '\0';
            return 0;
         }
      }
   }
   return -1;

}


//*****************************************************************************
int UrlString::FirstQuery( string &entry, string &value )
{
   findpos( );
   if( path_end < size() )
   {
      query = path_end;
      return NextQuery( entry, value );
   }
   return -1;
}


//*****************************************************************************
int UrlString::NextQuery( string &entry, string &value )
{
   int entry_start, entry_end, value_start, value_end;
   findpos( );
   if( !next_query_pos( entry_start, entry_end, value_start, value_end ) )
   {
      entry.assign( *this, entry_start, entry_end - entry_start );
      value.assign( *this, value_start, value_end - value_start );
      UrlDecode_s( entry );
      UrlDecode_s( value );
      return 0;
   }
   return -1;
}

//*****************************************************************************
int UrlString::next_query_pos( int &entry_start, int &entry_end,
                               int &value_start, int &value_end )
{
   unsigned int end = size();
   if(( query < end ) && ( query >= path_end ) )
   {
      query++;
      entry_start = query;
      value_end = find_first_of("+?", entry_start);
      if ( value_end < 0 )
      {
         query = end;
         value_end = end;
      }
      else
      {
         query = value_end;
      }

      value_start = find( '=', entry_start );
      if( (value_start < entry_start ) || (value_start > value_end )) 
      {
         value_start = value_end;
         entry_end = value_end;
      }
      else
      {
         entry_end = value_start;
         value_start++;
      }
      return 0;
   }
   return -1;
}

//*****************************************************************************
int UrlString::prepeare_for_query( void )
{
   findpos( );

   // Only posible if there is a url.
   if( url_begin < url_end )
   {
      if( path_begin == path_end )
      {
         insert( path_begin, "/" );
         path_end++;
      }

      if( path_end == size() )
      {
         append( "?" );
      }
      return 0;
   }
   return -1;
}

//*****************************************************************************
int UrlString::IsLocalFile( void )
{
   findpos( );

   // Is there a url ?
   if( url_begin < url_end )
   {
      return 0;
   }
   return 1;
}

//*****************************************************************************
int UrlString::Setport( unsigned int port )
{
   char buffer[10];

   findpos( );

   // Only posible if there is a url
   if(( port <= 0xFFFF ) && ( url_begin < url_end ))
   {
      buffer[0] = ':';
      gcvt(port, 6, buffer + 1);
      replace( url_end, path_begin - url_end, buffer );
      check = 1;
      return 0;
   }
   return -1;
}
//*****************************************************************************
int UrlString::GetPort( void )
{
   int size;
   char buffer[6];

   findpos( );
   if( url_end < path_begin )
   {
      size = path_begin - url_end - 1;
      if( size <= 5 )
      {
         copy(buffer, size, url_end + 1 );
         buffer[size] = '\0';
         return atoi( buffer );
      }
   }
   if( service_end > 0 )
   {
      for( size = 0; size < service_end; size++ )
      {
         at(size) = tolower(at(size));
      }
      return service_to_port( );
   }
   return -1;
}

//*****************************************************************************
int UrlString::service_to_port( void )
{
   if( !Cmp(0, service_end, "http" ) )
   {
      return 80;
   }
   if( !Cmp(0, service_end, "ftp" ) )
   {
      return 21;
   }
   if( !Cmp(0, service_end, "smtp" ) )
   {
      return 25;
   }
   if( !Cmp(0, service_end, "pop3" ) )
   {
      return 110;
   }
   return -1;
}

//*****************************************************************************
void UrlString::findpos( void )
{
   int temp;
   if( check )
   {
      service_end = find( "//" );
      if( service_end < 0 )
      {
         service_end = 0;
         user_begin = service_end;
      }
      else
      {
         user_begin = service_end+2;
         service_end--;
      }

      path_begin = find( '/', user_begin );
      if( path_begin < 0 )
      {
         path_begin = size();
      }

      if( !service_end && path_begin && (at(path_begin-1) == ':' ))
      {
         temp = find( '.' );
         if(( temp < 0 ) || ( temp > path_begin ))
         {
            service_end = path_begin - 1;
            user_begin = service_end;
            user_end = user_begin;
         }
      }

      user_end = find( '@', user_begin );
      if( ( user_end < 0 ) || ( user_end > path_begin ) )
      {
         user_end = user_begin;
         url_begin = user_end;
      }
      else
      {
         url_begin = user_end + 1;
      }

      // find ipv6 adresses.
      temp = find( '[', url_begin );

      if( ( temp >= 0 ) && ( temp < path_begin ))
      {
         url_end = find( ']', temp );
         if( url_end < path_begin )
         {
            url_end++;
         }
         else
         {
            url_end = url_begin;
         }
      }
      else
      {
         url_end = find( ':', url_begin );
         if( (url_end < 0) || ( url_end > path_begin ))
         {
            url_end = path_begin;
         }
      }
      path_end = find( '?', path_begin );
      if( path_end < path_begin )
      {
         path_end = size();
      }
      query = path_end;      
      check = 0;
   }
}

//*****************************************************************************
const char * UrlString::c_str( void )
{
   return string::c_str();
}



//*****************************************************************************
void UrlString::PathEncode( void )
{
   findpos( );
   UrlEncode_s( *this, path_begin, path_end - path_begin );
   check = 1;
}





//*****************************************************************************
void UrlString::PathDecode( void )
{
   findpos( );
   UrlDecode_s( *this, path_begin, path_end - path_begin );
   check = 1;
}

//*****************************************************************************
int UrlString::Cmp( size_type pos1, size_type n1,
                                UrlString& str, size_type pos2, size_type n2)
{
   #ifdef __STRING_STL
      return compare( pos1, n1, str, pos2, n2);
   #else
      if( n1 == n2 )
      {
         return strncmp( (char*)string::c_str() + pos1,
                                  (char*)str.string::c_str() + pos2, n1 );
      }
      return -1;
   #endif
}

//*****************************************************************************
int UrlString::Cmp( size_type pos, size_type n, char *str )
{
   #ifdef __STRING_STL
      return compare( pos, n, str);
   #else
      return strncmp( (char*)string::c_str() + pos, str, n );
   #endif
}

//*****************************************************************************
ostream& operator<<(ostream& csStream, UrlString& csUrl)
{
   switch( csUrl.urlcode )
   {
      case URL_ENCODE : csUrl.PathEncode( );
        break;
      case URL_DECODE : csUrl.PathDecode( );
        break;
      case URL_CODE_AS_IS : ;
        break;
   }
   return operator<<( csStream, (string&) csUrl);
}


//*****************************************************************************
istream& operator>>(istream& csStream, UrlString& csUrl)
{
   operator>>( csStream, (string&) csUrl);

   csUrl.check = 1;

   switch( csUrl.urlcode )
   {
      case URL_ENCODE : csUrl.PathEncode( );
        break;
      case URL_DECODE : csUrl.PathDecode( );
        break;
      case URL_CODE_AS_IS : ;
        break;
   }
   return csStream;
}



//*****************************************************************************
void HexCharToInt( char hex, int &value )
{
   if( (hex >= '0') && (hex <= '9') )
   {
      value |= (hex - '0');
   }
   else
   if( (hex >= 'a') && (hex <= 'f') )
   {
      value |= (hex - 'a' + 10);
   }
   else
   if( (hex >= 'A') && (hex <= 'F') )
   {
      value |= (hex - 'A' + 10);
   }
   else
   {
      value = -1;
   }
}

//*****************************************************************************
int UrlEncode(char *source, size_t s_size, char *dest, size_t d_size )
{
   unsigned int cnt = 0;
   int c;

   if( source && dest && (s_size <= d_size) )
   {
      if( !s_size )
      {
         s_size = strlen( source );
      }

      while( s_size && *source && ( cnt < d_size ))
      {
         if( (( *source >= '0' ) && ( *source <= '9' )) ||
             (( *source >= 'a' ) && ( *source <= 'z' )) ||
             (( *source >= 'A' ) && ( *source <= 'Z' )) ||
              ( *source == '/' ) || ( *source == '.' )  ||
              ( *source == '_' )                           )
         {
            *dest = *source;
         }
         else
         {
            if( (cnt + 2) < d_size )
            {
               if( ( *source == '%' ) && ( s_size > 2 ))
               {
                  HexCharToInt( *(source+1), c = 0 );
                  c = (c << 4) & 0xF0;
                  HexCharToInt( *(source+2), c );
                  if( c >= 0 )
                  {
                     source += 2;
                     s_size -= 2;
                  }
                  else
                  {
                     c = '%';
                  }
               }
               else
               {
                  c = *source;
               }
               *dest = '%';
               dest++;
               *dest = hex_char[(unsigned char)c >> 4];
               dest++;
               *dest = hex_char[(unsigned char)c & 0x0F];
               cnt += 2;
            }
            else
            {
               return -1;
            }
         }
         source++;
         s_size--;

         dest++;
         cnt++;
      }
      if( cnt < d_size )
      {
         *dest = '\0';

         return cnt;
      }
   }
   return -1;
}


//*****************************************************************************
int UrlDecode(char *source, size_t s_size, char *dest, size_t d_size )
{
   unsigned int cnt = 0;
   int c;

   if( source && dest && (s_size <= d_size) )
   {
      if( !s_size )
      {
         s_size = strlen( source );
      }

      while( s_size && *source && ( cnt < d_size ))
      {
         if( *source == '%' )
         {
            source++;
            HexCharToInt( *(source), c = 0 );
            c = (c << 4) & 0xF0;
            HexCharToInt( *(source+1), c );
            if( c >= 0 )
            {
               *dest = (char)c;
               source += 2;
               s_size -=2;
            }
            else
            {
               *dest = '%';
               if( *source == '%' )
               {
                  source++;
               }
            }
         }
         else
         {
            *dest = *source;
            source++;
         }
         s_size--;

         dest++;

         cnt++;
      }
      if( cnt < d_size )
      {
         *dest = '\0';
      }
      return cnt;
   }
   return -1;
}

//*****************************************************************************
string &UrlDecode_s( string &str, size_t pos, size_t n )
{
   unsigned int size;
   char *buffer;

   size = str.size();
   if( pos < size )
   {
      if( !n || ((pos + n) > size ))
      {
         n = size - pos;
      }
      buffer = (char *)str.c_str() + pos;
      size = UrlDecode(buffer, n, buffer, n );
      str.erase( pos + size, n - size);
   }
   return str;
}

//*****************************************************************************
string &UrlEncode_s( string &str, size_t pos, size_t n )
{

   unsigned int size, b_size;
   char *buffer;

   size = str.size();
   if( pos < size )
   {
      if( !n || ((pos + n) > size ))
      {
         n = size - pos;
      }
      b_size = n*3;
      buffer = new char[b_size];
      size = UrlEncode((char *)str.c_str() + pos, n, buffer, b_size );
      str.replace( pos, n, buffer);
      delete[] buffer;
   }
   return str;
}


#ifdef  CCXX_NAMESPACES
}
#endif




--------------000701060908070904000307
Content-Type: text/plain;
 name="url_string.h"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="url_string.h"

// 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.

//*****************************************************************************
#ifndef CCXX_URL_STRING_H
#define CCXX_URL_STRING_H

#ifndef CCXX_CONFIG_H_
#include <cc++/config.h>
#endif

#include "export.h"
#include "socket.h"
#include <string>
#include <iostream>


//*****************************************************************************
#ifdef  CCXX_NAMESPACES
namespace ost {
#endif

using namespace std;

//*****************************************************************************
/** @enum urlcode_t
    Used to deside if the string should be decoded or encoded.
    @see UrlString::urlcode
  */
enum urlcode_t { /// No modifications of the url.
                 URL_CODE_AS_IS,
                 /// Encode the url string, to send over a http stream
                 URL_ENCODE,
                 /// Decode the url string
                 URL_DECODE };

typedef enum urlcode_t urlcode_t;


//*****************************************************************************
class CCXX_CLASS_EXPORT UrlString;


/// @see UrlString::operator<<
ostream & operator<<(ostream & csStream, const UrlString& csUrl);
/// @see UrlString::operator>>
istream & operator>>(istream & csStream, UrlString& csUrl);


//*****************************************************************************
/** @class UrlString "url_class.h"
    Set and get the parts of an url.
    The following examples are supported :        \n
    service://user@url:port/path?query+query      \n
    service://url:port/path?query=1+query+query=2 \n
    service://user@url/path                       \n
    service://url:port                            \n
    service://url                                 \n
    url:port/path                                 \n
    url                                           \n
    user@url                                      \n
    /path                                         \n
    service:/path                                 \n
    service:///path                               \n
    @author arjan.paijralbe
    @date   10-2-2002
 */
class UrlString : protected string
{
   public :

      /** Constructor of the class.
          This constructor creates an empty class.
          @param urlcode Sets the url coding for the stream operators.
        */
      UrlString( urlcode_t urlcode = URL_ENCODE );
      /** Constructor of the class.
          This constructor copy the url from the char buffer.
          @param url Pointer to a char buffer with an url
          @param urlcode Sets the url coding for the stream operators.
        */
      UrlString( char *url, urlcode_t urlcode = URL_ENCODE );
      /** Constructor of the class.
          This constructor copy the url from the string.
          @param url Reference to a string with an url
          @param urlcode Sets the url coding for the stream operators.
        */
      UrlString( string &url, urlcode_t urlcode = URL_ENCODE );
      /** Constructor of the class.
          This constructor copy the url from the UrlString.
          @param url Reference to a string with an url
        */
      UrlString( UrlString &url );

      /** Constructor of the class.
          This constructor takes the the url from address.
          @param address Contains the url.
          @param urlcode sets the url coding for the stream operators.
        */
      UrlString( InetAddress &address, urlcode_t urlcode = URL_ENCODE );

      /** Destructor of the class.
        */
      virtual ~UrlString( void );

      /// This operator assign a new url to the class.
      UrlString& operator=( char *url );
      /// This operator assign a new url to the class.
      UrlString& operator=( string &url );
      /// This operator assign a new url to the class.
      UrlString& operator=( UrlString &url );

      /** This operator set a new coding mode of the class.
          @see urlcode
        */
      UrlString& operator=( urlcode_t urlcode );

      /** This operator compares the url the path and the port of
          both classes for eaquality.
          The service and the query will be ignored.
        */
      bool operator==( UrlString &url );

      /** This operator compares the url the path both classes to find out
          witch one is bigger....
          The service the query and the port will be ignored.
        */
      bool operator>( UrlString &url );

      /** This operator compares the url the path both classes to find out
          witch one is smaller....
          The service the query and the port will be ignored.
        */
      bool operator<( UrlString &url );


      /// This methode assign a new url to the class.
      UrlString& assign( char *url );
      /// This methode assign a new url to the class.
      UrlString& assign( UrlString &url );
      /// This methode assign a new url to the class.
      UrlString& assign( string &url );

      /** This methode returns the specified service of the url.
          If there is no service specified the buffer will be empty.
          The service has no ':' char at the end!
          @param buffer In this buffer the service is been inserted.
          @param size Size of the buffer.
          @retval buffer The service is been copyed.
          @retval NULL Not enough space in the buffer.
        */
      char *GetService( char *buffer, size_t size );

      /** This methode returns the specified service of the url.
          If there is no service specified the buffer will be empty.
          The service has no ':' char at the end!
          @param str In this buffer the service is been inserted.
          @return str.
        */
      string GetService( void );

      /** This methode set the service of the url.
          The should no ':' char at the end!
          @param service Service to set.
        */
      void SetService( char *service );


      /** This methode get the service from the urlstring class and set it this class.
          @param service Service to set.
        */
      void SetService( UrlString &service );

      /** This methode returns the specified user of the url.
          If there is no user specified the buffer will be empty.
          @param buffer In this buffer the user is been inserted.
          @param size Size of the buffer.
          @retval buffer The user is been copyed.
          @retval NULL Not enough space in the buffer.

        */
      char *GetUser( char *buffer, size_t size );

      /** This methode returns the specified user of the url.
          If there is no user specified the buffer will be empty.
          @param str In this buffer the user is been inserted.
          @return str.
        */
      string GetUser( void );

      /** This methode set the user of the url.
          @param user User to set.

        */
      int SetUser( char *user );

      /** This methode set the user of the url.
          @param user User to set.

        */
      int SetUser( UrlString &user );


      /** This methode erase the user from the url.
        */
      void EraseUser( void );

      /** This methode returns the specified url.
          If there is no url specified the buffer will be empty.
          @param buffer In this buffer the url is been inserted.
          @param size Size of the buffer.
          @retval buffer The url is been copyed.
          @retval NULL Not enough space in the buffer.
        */
      char *GetUrl( char *buffer, size_t size );

      /** This methode returns the specified url.
          If there is no url specified the buffer will be empty.
          @param str In this buffer the url is been inserted.
          @return str.
        */
      string GetUrl( void );

      /** This methode set the url.
          @param url Url to set.
        */
      void SetUrl( char *url );

      /** This methode get the url from the urlstring class and set it to this class.
          @param url Url to set.
          @warning workes only if url contains an url!
        */
      void SetUrl( UrlString &url );

      /** This methode takes the url from the address if it is a valid adress.
          @param address Contains the address to the url.
          @see InetAddress::getHostname
        */
      void SetUrl( InetAddress &address );

      /** This methode insert the url to the InetAddress class.
          @see InetAddress::operator=
          @return address
        */
      InetAddress &GetAdresss( InetAddress &address );

      /** This methode returns the specified path of the url.
          If there is no path specified the buffer contains '/'.
          @param buffer In this buffer the path is been inserted.
          @param size Size of the buffer.
          @retval buffer The path is been copyed.
          @retval NULL Not enough space in the buffer.
        */
      char *GetPath( char *buffer, size_t size );

      /** This methode returns the specified path of the url.
          If there is no path specified the buffer contains '/'.
          @param str In this buffer the path is been inserted.
          @return str.
        */
      string GetPath( void );

      /** This methode set the path of the url.
          If the first char is not an '/' it will be added.
          @param path Path to set.
        */
      void SetPath( char *path );

      /** This methode takes the path from the urlstring class and add it to this class.
          @param path Path to set.
        */
      void SetPath( UrlString &path );

      /** This methode returns the specified query of the url.
          If there is no query specified the buffer will be empty.
          @param buffer In this buffer the query is been inserted.
          @param size Size of the buffer.
          @retval buffer The query is been copyed.
          @retval NULL Not enough space in the buffer.
        */
      char *GetQuery( char *buffer, size_t size );

      /** This methode returns the specified query of the url.
          If there is no query specified the buffer will be empty.
          @param str In this buffer the query is been inserted.
          @return str.
        */
      string GetQuery( void );

      /** This methode set the query of the url.
          If the first char is not an '/' it will be added.
          @param query Query to set.
        */
      int  SetQuery( char *query );


      /** This methode get the query from the urlstring class and set it to this class.
          If the first char is not an '/' it will be added.
          @param query Query to set.
        */
      int  SetQuery( UrlString &query );

      /// This methode erase the query from the url.
      void EraseQuery( void );

      /** This methode add's a new entry to the query.
          The entry and the value will first encoded and then added to the url.
          To seperate the entry's the '+' character is been used.
          @param entry Name of the entry.
          @arg entry = NULL No query will be added.
          @param value Value of the entry.
          @arg value = NULL only the entry will be added.
         */
      void AddQuery( char* entry, char * value );

      /** This methode get the first query entry and decode it.
          @param entry Buffer for the name of the entry.
          @param e_size Size of the entry buffer.
          @param value Buffer for the value of the entry.
          @param v_size Size of the value buffer.
          @retval 0 The first entry found.
          @retval -1 No entry found or size of the buffer is to small.
          @see NextQuery, AddQuery;
         */
      int FirstQuery( char* entry, size_t e_size, char * value, size_t v_size );

      /** This methode get the first query entry and decode it.
          @param entry Buffer for the name of the entry.
          @param value Buffer for the value of the entry.
          @retval 0 The first entry found.
          @retval -1 No entry found.
          @see NextQuery, AddQuery;
         */

      int FirstQuery( string &entry, string &value );

      /** This methode get the next query entry and decode it.
          @param entry Buffer for the name of the entry.
          @param e_size Size of the entry buffer.
          @param value Buffer for the value of the entry.
          @param v_size Size of the value buffer.
          @retval 0 The first entry found.
          @retval -1 No entry found or size of the buffer is to small.
          @see FirstQuery, AddQuery;
         */
      int NextQuery( char* entry, size_t e_size, char * value, size_t v_size );

      /** This methode get the next query entry and decode it.
          @param entry Buffer for the name of the entry.
          @param value Buffer for the value of the entry.
          @retval 0 The first entry found.
          @retval -1 No entry found.
          @see FirstQuery, AddQuery;
         */
      int NextQuery( string &entry, string &value );

      /** Set the port number.
          @warning only possible if a url is specified.
        */
      int Setport( unsigned int port );

      /**  This returns the specified port.
           If there is no port, the methode #service_to_port is been
           called to translate the servic to a port number.
           @retval 0..65535 specified port.
           @retval -1 no port specified.
         */
      int GetPort( void );

      /** Checks if there is a url specified.
          @retval 0 It has a url.
          @retval 1 There is no url, so it will be a local file.
        */
      int IsLocalFile( void );

      /** Decode the path of the string.
        */
      void PathDecode( void );


      /** Encode the path of the string.
        */
      void PathEncode( void );

      /** Get the string as zero terminated char buffer.
        */
      const char * c_str( void );

      /// Methode to stream the class.
      friend ostream& operator<<(ostream& csStream, UrlString& csUrl);
      /// Methode to get the url information from a stream.
      friend istream& operator>>(istream& csStream, UrlString& csUrl);

   protected :
      /// End position of the service.
      int service_end;
      /// begin position of the user.
      int user_begin;
      /// end position of the user.
      int user_end;
      /// begin position of the url.
      int url_begin;
      /// end position of the url.
      int url_end;
      /// begin position of the path.
      int path_begin;
      /// end position of the path.
      int path_end;
      /// start position of the last readed query entry.
      int query;

      /** Is been used with the operator<< and operator>> to decide if the
          path should be encoded or coded.
          @see urlcode_t
         */
      urlcode_t urlcode;

      /** Status of string modifications.
          @arg check == 0 string is not modified.
          @arg check != 0 string is modified, findpos should be called.
        */
      int check;

      /** scanns the structure of the url and is updating the position
          attributs of the class.
        */
      void findpos( void );

      /** Translate the service to a port number.
          Is been called by GetPort, if there is no port specified.
          @retval 21 if service = 'ftp'
          @retval 25 if service = 'smpt'
          @retval 80 if service = 'http'
          @retval -1 unknown service port.
        */
      virtual int service_to_port( void );

      /** get the positions of the next qery entry.
        */
      inline int next_query_pos( int &entry_start, int &entry_end,
                                 int &value_start, int &value_end );

   private :
      // prepeats the string to add a querry.
      int prepeare_for_query( void );
      inline int Cmp( size_type pos1, size_type n1,
                            UrlString& str, size_type pos2, size_type n2);
      inline int Cmp( size_type pos, size_type n, char *str );
};

//*****************************************************************************
/** @defgroup global Global
 *  Global Functions and attributs.
 */

/** Encode a string.
    @param source  string to encode.
    @param s_size  size of the encoded string.
    @arg   s_size = 0 takes the size of the source string.
    @arg   s_size > string size  it will takes the size of the source string
    @arg   s_size < string size  it will takes s_size.
    @param dest    buffer for the encoded string.
    @param d_size  size of the buffer ( has to be 3 * s_size )
    @retval 0 string is been encoded.
    @retval -1 not enough space in the destination buffer.
    @see #url_string.h
    @ingroup global
  */
int UrlEncode( char *source, size_t s_size, char *dest, size_t d_size );

/** Decode a string.
    @param source  string to decode.
    @param s_size  size of the decoded string.
    @arg   s_size = 0 takes the size of the source string.
    @arg   s_size > string size  it will takes the size of the source string
    @arg   s_size < string size  it will takes s_size.
    @param dest    buffer for the decoded string.
    @param d_size  size of the buffer ( has to be at minimum s_size )
    @retval 0 string is been encoded.
    @retval -1 not enough space in the destination buffer.
    @see #url_string.h
    @ingroup global
  */
int UrlDecode( char *source, size_t s_size, char *dest, size_t d_size );

/** Encode a string.
    @param str  string to encode.
    @param pos  start position to encode
    @param n    size to encode.
    @arg   n = 0 size from pos to end()
    @return reference to str.
    @see #url_string.h
    @ingroup global
  */
string &UrlEncode_s( string &str, size_t pos = 0, size_t n = 0 );

/** Decode a string.
    @param str  string to encode.
    @param pos  start position to encode
    @param n    size to encode.
    @arg   n = 0 size from pos to end()
    @return reference to str.
    @see #url_string.h
    @ingroup global
  */
string &UrlDecode_s( string &str, size_t pos = 0, size_t n = 0 );

#ifdef  CCXX_NAMESPACES
}
#endif

#endif





--------------000701060908070904000307--



From dyfet@ostel.com Sun Feb 10 15:24:21 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16a0WF-00035w-00
	for <bug-commoncpp@gnu.org>; Sun, 10 Feb 2002 15:24:15 -0500
Received: from ostel.com (home [172.16.1.254])
	by home.sys (Postfix) with ESMTP
	id 5E1823997D; Sun, 10 Feb 2002 15:39:26 -0500 (EST)
Message-ID: <3C66DA7E.9030900@ostel.com>
Date: Sun, 10 Feb 2002 15:39:26 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.4) Gecko/20010914
X-Accept-Language: en-us
MIME-Version: 1.0
To: arjan derk-jan paijralbe <arjan.paijralbe@bluewin.ch>
Cc: bug-commoncpp@gnu.org
Subject: Re: New Class for the library
References: <3C669395.2040704@bluewin.ch>
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 is interesting.  I tend to think url_string.h should itself just be 
in url.h so all url stuff is under a single header.  Other than that, I 
think it may be possible to adopt this class into the project largely as 
is.  There already is a string function for handing encoding/decoding of 
url escaped strings, although it operates on pure "char" arrays rather 
than on std::string.  In structuring the Get() request with queries, 
this could be very useful.



arjan derk-jan paijralbe wrote:

> Hi
> A good library, so I've a new class for it.
> It is a string class to handle urls's.
> I've also add an entry for doxygen to doc global functions.
>
> kind regards
>   arjan
>
>
>------------------------------------------------------------------------
>
>// 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 "url_string.h"
>#include <cstdlib>
>#include <stdlib.h>
>
>#ifdef  CCXX_NAMESPACES
>namespace ost {
>#endif
>
>
>//*****************************************************************************
>static char *hex_char = "0123456789abcdef";
>
>//*****************************************************************************
>UrlString::UrlString( urlcode_t _urlcode )
>          :string(), urlcode(_urlcode), check(1)
>{
>}
>
>//*****************************************************************************
>UrlString::UrlString( char *url, urlcode_t _urlcode )
>          :string( url ), urlcode(_urlcode), check(1)
>{
>}
>
>//*****************************************************************************
>UrlString::UrlString( string &url, urlcode_t _urlcode )
>          :string( url ), urlcode(_urlcode), check(1)
>{
>}
>
>//*****************************************************************************
>UrlString::UrlString( UrlString &url )
>          :string( url ), urlcode(url.urlcode), check(1)
>{
>}
>
>//*****************************************************************************
>UrlString::UrlString( InetAddress &address, urlcode_t urlcode )
>               :string(), urlcode(urlcode), check(1)
>{
>   SetUrl( address );
>}
>
>//*****************************************************************************
>UrlString::~UrlString( void )
>{
>
>}
>
>//*****************************************************************************
>UrlString& UrlString::operator=( char *url )
>{
>   return assign( url );
>}
>
>//*****************************************************************************
>UrlString& UrlString::operator=( UrlString &url )
>{
>   return assign( url );
>}
>
>//*****************************************************************************
>UrlString& UrlString::operator=( string &url )
>{
>   return assign( url );
>}
>
>//*****************************************************************************
>UrlString& UrlString::operator=( urlcode_t _urlcode )
>{
>   urlcode = _urlcode;
>   return *this;
>}
>
>//*****************************************************************************
>bool UrlString::operator==( UrlString &url )
>{
>   findpos();
>   url.findpos();
>
>   return !Cmp( (int)url_begin, url_end - url_begin,
>                   url, (int)url.url_begin, url.url_end - url.url_begin ) &&
>          !Cmp( (int)path_begin, path_end - path_begin,
>                url, (int)url.path_begin, url.path_end - url.path_begin ) &&
>                  (GetPort() == url.GetPort());
>}
>
>
>//*****************************************************************************
>bool UrlString::operator>( UrlString &url )
>{
>   int result;
>   findpos();
>   url.findpos();
>
>   result = Cmp( url_begin, url_end - url_begin,
>                          url, url.url_begin, url.url_end - url.url_begin );
>   if( result == 0 )
>   {
>      return (Cmp( path_begin, path_end - path_begin,
>                 url, url.path_begin, url.path_end - url.path_begin ) > 0 );
>   }
>   return (result > 0);
>}
>
>//*****************************************************************************
>bool UrlString::operator<( UrlString &url )
>{
>   int result;
>   findpos();
>   url.findpos();
>
>   result = Cmp( url_begin, url_end - url_begin,
>                          url, url.url_begin, url.url_end - url.url_begin );
>   if( result == 0 )
>   {
>      return (Cmp( path_begin, path_end - path_begin,
>                 url, url.path_begin, url.path_end - url.path_begin ) < 0 );
>   }
>   return (result < 0);
>}
>
>
>//*****************************************************************************
>UrlString& UrlString::assign( char *url )
>{
>   check = 1;
>   string::assign( url );
>   return *this;
>}
>
>//*****************************************************************************
>UrlString& UrlString::assign( UrlString &url )
>{
>   check = 1;
>   string::assign( url );
>   return *this;
>}
>
>//*****************************************************************************
>UrlString& UrlString::assign( string &url )
>{
>   check = 1;
>   string::assign( url );
>   return *this;
>}
>
>//*****************************************************************************
>char *UrlString::GetService( char *buffer, size_t size )
>{
>   findpos( );
>   if( buffer && ( service_end < size ))
>   {
>      if( service_end > 0 )
>      {
>         copy( buffer, service_end, 0 );
>         buffer[service_end] = '\0';
>      }
>      else
>      {
>         buffer[0] = '\0';
>      }
>      return buffer;
>   }
>   return NULL;
>}
>
>//*****************************************************************************
>string UrlString::GetService( void )
>{
>   findpos( );
>   if( service_end > 0 )
>   {
>      return string( *this, 0, service_end );
>   }
>   else
>   {
>      return string();
>   }
>}
>
>//*****************************************************************************
>void UrlString::SetService( char *service )
>{
>   if( service )
>   {
>      findpos( );
>
>      if( service_end > 0 )
>      {
>         replace( 0, service_end, service );
>      }
>      else
>      {
>         insert( 0, "://" );
>         insert( 0, service );
>      }
>      check = 1;
>   }
>}
>
>//*****************************************************************************
>void UrlString::SetService( UrlString &service )
>{
>   service.findpos( );
>   findpos( );
>
>   if( service.service_end > 0 )
>   {
>      if( service_end > 0 )
>      {
>         replace( 0, service_end, service, 0, service.service_end );
>      }
>      else
>      {
>         insert( 0, "://" );
>         insert( 0, service, 0, service.service_end );
>      }
>      check = 1;
>   }
>}
>
>
>//*****************************************************************************
>char *UrlString::GetPath( char *buffer, size_t size )
>{
>   int copy_size;
>
>   findpos( );
>   copy_size = path_end - path_begin;
>
>   if( buffer && ( size > copy_size ) && ( size > 2 ))
>   {
>      if( path_begin < path_end )
>      {
>         copy_size = UrlDecode((char*)string::c_str() + path_begin,
>                                                     copy_size, buffer, size );
>         if( copy_size >= 0 )
>         {
>            buffer[copy_size] = '\0';
>         }
>         else
>         {
>            return NULL;
>         }
>      }
>      else
>      {
>         strcpy( buffer, "/" );
>      }
>      return buffer;
>   }
>   return NULL;
>}
>
>//*****************************************************************************
>string UrlString::GetPath( void )
>{
>   findpos( );
>
>   if( path_begin < path_end )
>   {
>      string temp;
>      temp = string( *this, path_begin, path_end - path_begin );
>      UrlDecode_s( temp );
>      return temp;
>   }
>   else
>   {
>      return string( "/" );
>   }
>}
>
>//*****************************************************************************
>void UrlString::SetPath( char *path )
>{
>   if( path )
>   {
>      findpos( );
>
>      if( path_begin < path_end )
>      {
>         if( *path != '/' )
>         {
>            path_begin++;
>         }
>         replace( path_begin, path_end - path_begin, path );
>      }
>      else
>      {
>         if( *path != '/' )
>         {
>            insert( path_begin, "/" );
>            path_begin++;
>         }
>         insert( path_begin, path );
>      }
>      check = 1;
>   }
>}
>
>//*****************************************************************************
>void UrlString::SetPath( UrlString &path )
>{
>   unsigned int size, path_size;
>   findpos( );
>   path.findpos( );
>
>   size = path_end - path_begin;
>   path_size = path.path_end - path.path_begin;
>
>   if( size > 0 )
>   {
>      if( path_size > 0)
>      {
>         replace( path_begin, size, path, path.path_begin, path_size );
>      }
>      else
>      {
>         replace( path_begin, size, "/" );
>      }
>   }
>   else
>   {
>      if( path_size > 0)
>      {
>         insert( path_begin, path, path.path_begin, path_size );
>      }
>      else
>      {
>         insert( path_begin, "/" );
>      }
>   }
>   check = 1;
>}
>
>
>//*****************************************************************************
>char *UrlString::GetUrl( char *buffer, size_t size )
>{
>   unsigned int copy_size;
>
>   findpos( );
>   copy_size = url_end - url_begin;
>
>   if( buffer && ( size > copy_size ) && size)
>   {
>      if( url_begin < url_end )
>      {
>         copy( buffer, copy_size, url_begin );
>         buffer[copy_size] = '\0';
>      }
>      else
>      {
>         buffer[0] = '\0';
>      }
>      return buffer;
>   }
>   return NULL;
>}
>
>//*****************************************************************************
>string UrlString::GetUrl( void )
>{
>   findpos( );
>   if( url_begin < url_end )
>   {
>      return string( *this, url_begin, url_end - url_begin );
>   }
>   else
>   {
>      return string();
>   }
>}
>
>
>//*****************************************************************************
>void UrlString::SetUrl( char *url )
>{
>   if( url )
>   {
>      findpos( );
>
>      if( url_begin < url_end )
>      {
>         replace( url_begin, url_end - url_begin, url );
>      }
>      else
>      {
>         insert( url_begin, url );
>      }
>      check = 1;
>   }
>}
>
>
>//*****************************************************************************
>void UrlString::SetUrl( UrlString &url )
>{
>   unsigned int size, url_size;
>   findpos( );
>   url.findpos( );
>
>   size = url_end - url_begin;
>   url_size = url.url_end - url.url_begin;
>
>   findpos( );
>   url.findpos( );
>
>   if( url_size > 0 )
>   {
>      if( size > 0 )
>      {
>         replace( url_begin, size, url, url.url_begin, url_size );
>      }
>      else
>      {
>         insert( url_begin, url, url.url_begin, url_size );
>      }
>      check = 1;
>   }
>}
>
>//*****************************************************************************
>void UrlString::SetUrl( InetAddress &address )
>{
>   // A valid address ?
>   if( address.isInetAddress() )
>   {
>      SetUrl( (char*)address.getHostname() );
>   }
>}
>
>
>
>//*****************************************************************************
>InetAddress &UrlString::GetAdresss( InetAddress &address )
>{
>   char *buffer;
>   unsigned int copy_size;
>
>   findpos( );
>
>   copy_size = (url_end - url_begin)  + 1;
>
>   if( url_begin < url_end )
>   {
>      buffer = new char[copy_size];
>
>      copy( buffer, copy_size, url_begin );
>      buffer[copy_size] = '\0';
>      address = (const char*)buffer;
>
>      delete[] buffer;
>   }
>   else
>   {
>      address = (unsigned long)0;
>   }
>   return address;
>}
>
>
>//*****************************************************************************
>char *UrlString::GetUser( char *buffer, size_t size )
>{
>   unsigned int copy_size;
>
>   findpos( );
>   copy_size = path_end - path_begin;
>
>   if( buffer && ( size > copy_size ) && ( size > 2 ))
>   {
>      if( user_begin < user_end )
>      {
>         copy( buffer, copy_size, user_begin );
>         buffer[copy_size] = '\0';
>      }
>      else
>      {
>         buffer[0] = '\0';
>      }
>      return buffer;
>   }
>   return NULL;
>}
>
>//*****************************************************************************
>string UrlString::GetUser( void )
>{
>   findpos( );
>   if( user_begin < user_end )
>   {
>      return string( *this, user_begin, user_end - user_begin);
>   }
>   else
>   {
>      return string( );
>   }
>}
>
>//*****************************************************************************
>int UrlString::SetUser( char *user )
>{
>   if( user )
>   {
>      findpos( );
>
>      // Only posible if there is a url.
>      if( url_begin < url_end )
>      {
>         if( user_begin < user_end )
>         {
>            replace( user_begin, user_end - user_begin, user );
>         }
>         else
>         {
>            insert( user_begin, "@" );
>            insert( user_begin, user );
>         }
>         check = 1;
>         return 0;
>      }
>   }
>   return -1;
>}
>
>
>//*****************************************************************************
>int UrlString::SetUser( UrlString &user )
>{
>   unsigned int size, user_size;
>
>   findpos( );
>   user.findpos( );
>
>   size =  user_end - user_begin;
>   user_size=  user.user_end - user.user_begin;
>
>   // Only posible if there is a url.
>   if( url_begin < url_end )
>   {
>      if( user_size > 0 )
>      {
>         if( size > 0 )
>         {
>            replace( user_begin, size, user, user.user_begin, user_size );
>         }
>         else
>         {
>            insert( user_begin, user, user.user_begin, user_size + 1 );
>         }
>      }
>      check = 1;
>   }
>}
>
>//*****************************************************************************
>void UrlString::EraseUser( void )
>{
>   findpos( );
>   if( user_begin < user_end )
>   {
>      erase( user_begin, user_end + 1 );
>   }
>}
>
>//*****************************************************************************
>char *UrlString::GetQuery( char *buffer, size_t size )
>{
>   unsigned int copy_size;
>   int end;
>
>   findpos( );
>   end = string::size();
>   copy_size = end - path_end;
>
>   if( buffer && ( size > copy_size ) && size )
>   {
>      if( path_end < end )
>      {
>         copy_size--;
>         copy( buffer, copy_size, path_end + 1 );
>         buffer[copy_size] = '\0';
>      }
>      else
>      {
>         buffer[0] = '\0';
>      }
>      return buffer;
>   }
>   return NULL;
>}
>
>//*****************************************************************************
>string UrlString::GetQuery( void )
>{
>   int end;
>   findpos( );
>
>   end = size() - 1;
>   if( path_end < end )
>   {
>      return string( *this, path_end + 1, end - path_end );
>   }
>   else
>   {
>      return string( );
>   }
>}
>
>//*****************************************************************************
>int UrlString::SetQuery( char *query )
>{
>   if( query && !prepeare_for_query( ) )
>   {
>      if( *query == '?' )
>      {
>         query++;
>      }
>      replace( path_end + 1, size() - path_end - 1, query );
>
>      return 0;
>   }
>   return -1;
>}
>
>
>//*****************************************************************************
>int UrlString::SetQuery( UrlString &query )
>{
>   unsigned int query_size;
>
>   query.findpos( );
>   query_size = query.size() - query.path_end;
>
>   if( query_size > 0 )
>   {
>      if( !prepeare_for_query( ) )
>      {
>         replace( path_end, size() - path_end, query, query.path_end, query_size );
>      }
>      return 0;
>   }
>   return -1;
>}
>
>//*****************************************************************************
>void UrlString::EraseQuery( void )
>{
>   int end;
>
>   findpos( );
>
>   end = size();
>
>   if( path_end < end )
>   {
>      erase( path_end, end );
>      check = 1;
>   }
>}
>
>//*****************************************************************************
>void UrlString::AddQuery( char* entry, char * value )
>{
>   char *buffer;
>   int b_size, e_size, v_size = 0;
>
>   if( !prepeare_for_query( ) && entry )
>   {
>      e_size = strlen( entry );
>      b_size = e_size;
>      if( value )
>      {
>         v_size = strlen( value );
>      }
>      if( e_size < v_size )
>      {
>         b_size = v_size;
>      }
>      b_size *= 3;
>      buffer = new char[b_size];
>      UrlEncode(entry, e_size, buffer, b_size );
>      if( *rbegin() != '?' )
>      {
>         append("+");
>      }
>      append(buffer);
>      if( value )
>      {
>         append("=");
>         UrlEncode(value, v_size, buffer, b_size );
>         append(buffer);
>      }
>      delete[] buffer;
>   }
>}
>
>//*****************************************************************************
>int UrlString::FirstQuery( char* entry, size_t e_size,
>                                                 char * value, size_t v_size )
>{
>   findpos( );
>   if( path_end < size() )
>   {
>      query = path_end;
>      return NextQuery( entry, e_size, value, v_size );
>   }
>   return -1;
>}
>
>//*****************************************************************************
>int UrlString::NextQuery( char* entry, size_t e_size,
>                                                 char* value, size_t v_size )
>{
>   int entry_start, entry_end, value_start, value_end;
>   char *start;
>   findpos( );
>   if( !next_query_pos( entry_start, entry_end, value_start, value_end ) )
>   {
>      start = (char*)string::c_str();
>      if( entry && UrlDecode( start + entry_start,
>                                entry_end - entry_start, entry, e_size ) >= 0 )
>      {
>         if( value && ( value_start < value_end ) &&
>            ( UrlDecode( start + value_start,
>                               value_end - value_start, value, v_size ) >= 0 ))
>         {
>            return 0;
>         }
>         else
>         {
>            *value = '\0';
>            return 0;
>         }
>      }
>   }
>   return -1;
>
>}
>
>
>//*****************************************************************************
>int UrlString::FirstQuery( string &entry, string &value )
>{
>   findpos( );
>   if( path_end < size() )
>   {
>      query = path_end;
>      return NextQuery( entry, value );
>   }
>   return -1;
>}
>
>
>//*****************************************************************************
>int UrlString::NextQuery( string &entry, string &value )
>{
>   int entry_start, entry_end, value_start, value_end;
>   findpos( );
>   if( !next_query_pos( entry_start, entry_end, value_start, value_end ) )
>   {
>      entry.assign( *this, entry_start, entry_end - entry_start );
>      value.assign( *this, value_start, value_end - value_start );
>      UrlDecode_s( entry );
>      UrlDecode_s( value );
>      return 0;
>   }
>   return -1;
>}
>
>//*****************************************************************************
>int UrlString::next_query_pos( int &entry_start, int &entry_end,
>                               int &value_start, int &value_end )
>{
>   unsigned int end = size();
>   if(( query < end ) && ( query >= path_end ) )
>   {
>      query++;
>      entry_start = query;
>      value_end = find_first_of("+?", entry_start);
>      if ( value_end < 0 )
>      {
>         query = end;
>         value_end = end;
>      }
>      else
>      {
>         query = value_end;
>      }
>
>      value_start = find( '=', entry_start );
>      if( (value_start < entry_start ) || (value_start > value_end )) 
>      {
>         value_start = value_end;
>         entry_end = value_end;
>      }
>      else
>      {
>         entry_end = value_start;
>         value_start++;
>      }
>      return 0;
>   }
>   return -1;
>}
>
>//*****************************************************************************
>int UrlString::prepeare_for_query( void )
>{
>   findpos( );
>
>   // Only posible if there is a url.
>   if( url_begin < url_end )
>   {
>      if( path_begin == path_end )
>      {
>         insert( path_begin, "/" );
>         path_end++;
>      }
>
>      if( path_end == size() )
>      {
>         append( "?" );
>      }
>      return 0;
>   }
>   return -1;
>}
>
>//*****************************************************************************
>int UrlString::IsLocalFile( void )
>{
>   findpos( );
>
>   // Is there a url ?
>   if( url_begin < url_end )
>   {
>      return 0;
>   }
>   return 1;
>}
>
>//*****************************************************************************
>int UrlString::Setport( unsigned int port )
>{
>   char buffer[10];
>
>   findpos( );
>
>   // Only posible if there is a url
>   if(( port <= 0xFFFF ) && ( url_begin < url_end ))
>   {
>      buffer[0] = ':';
>      gcvt(port, 6, buffer + 1);
>      replace( url_end, path_begin - url_end, buffer );
>      check = 1;
>      return 0;
>   }
>   return -1;
>}
>//*****************************************************************************
>int UrlString::GetPort( void )
>{
>   int size;
>   char buffer[6];
>
>   findpos( );
>   if( url_end < path_begin )
>   {
>      size = path_begin - url_end - 1;
>      if( size <= 5 )
>      {
>         copy(buffer, size, url_end + 1 );
>         buffer[size] = '\0';
>         return atoi( buffer );
>      }
>   }
>   if( service_end > 0 )
>   {
>      for( size = 0; size < service_end; size++ )
>      {
>         at(size) = tolower(at(size));
>      }
>      return service_to_port( );
>   }
>   return -1;
>}
>
>//*****************************************************************************
>int UrlString::service_to_port( void )
>{
>   if( !Cmp(0, service_end, "http" ) )
>   {
>      return 80;
>   }
>   if( !Cmp(0, service_end, "ftp" ) )
>   {
>      return 21;
>   }
>   if( !Cmp(0, service_end, "smtp" ) )
>   {
>      return 25;
>   }
>   if( !Cmp(0, service_end, "pop3" ) )
>   {
>      return 110;
>   }
>   return -1;
>}
>
>//*****************************************************************************
>void UrlString::findpos( void )
>{
>   int temp;
>   if( check )
>   {
>      service_end = find( "//" );
>      if( service_end < 0 )
>      {
>         service_end = 0;
>         user_begin = service_end;
>      }
>      else
>      {
>         user_begin = service_end+2;
>         service_end--;
>      }
>
>      path_begin = find( '/', user_begin );
>      if( path_begin < 0 )
>      {
>         path_begin = size();
>      }
>
>      if( !service_end && path_begin && (at(path_begin-1) == ':' ))
>      {
>         temp = find( '.' );
>         if(( temp < 0 ) || ( temp > path_begin ))
>         {
>            service_end = path_begin - 1;
>            user_begin = service_end;
>            user_end = user_begin;
>         }
>      }
>
>      user_end = find( '@', user_begin );
>      if( ( user_end < 0 ) || ( user_end > path_begin ) )
>      {
>         user_end = user_begin;
>         url_begin = user_end;
>      }
>      else
>      {
>         url_begin = user_end + 1;
>      }
>
>      // find ipv6 adresses.
>      temp = find( '[', url_begin );
>
>      if( ( temp >= 0 ) && ( temp < path_begin ))
>      {
>         url_end = find( ']', temp );
>         if( url_end < path_begin )
>         {
>            url_end++;
>         }
>         else
>         {
>            url_end = url_begin;
>         }
>      }
>      else
>      {
>         url_end = find( ':', url_begin );
>         if( (url_end < 0) || ( url_end > path_begin ))
>         {
>            url_end = path_begin;
>         }
>      }
>      path_end = find( '?', path_begin );
>      if( path_end < path_begin )
>      {
>         path_end = size();
>      }
>      query = path_end;      
>      check = 0;
>   }
>}
>
>//*****************************************************************************
>const char * UrlString::c_str( void )
>{
>   return string::c_str();
>}
>
>
>
>//*****************************************************************************
>void UrlString::PathEncode( void )
>{
>   findpos( );
>   UrlEncode_s( *this, path_begin, path_end - path_begin );
>   check = 1;
>}
>
>
>
>
>
>//*****************************************************************************
>void UrlString::PathDecode( void )
>{
>   findpos( );
>   UrlDecode_s( *this, path_begin, path_end - path_begin );
>   check = 1;
>}
>
>//*****************************************************************************
>int UrlString::Cmp( size_type pos1, size_type n1,
>                                UrlString& str, size_type pos2, size_type n2)
>{
>   #ifdef __STRING_STL
>      return compare( pos1, n1, str, pos2, n2);
>   #else
>      if( n1 == n2 )
>      {
>         return strncmp( (char*)string::c_str() + pos1,
>                                  (char*)str.string::c_str() + pos2, n1 );
>      }
>      return -1;
>   #endif
>}
>
>//*****************************************************************************
>int UrlString::Cmp( size_type pos, size_type n, char *str )
>{
>   #ifdef __STRING_STL
>      return compare( pos, n, str);
>   #else
>      return strncmp( (char*)string::c_str() + pos, str, n );
>   #endif
>}
>
>//*****************************************************************************
>ostream& operator<<(ostream& csStream, UrlString& csUrl)
>{
>   switch( csUrl.urlcode )
>   {
>      case URL_ENCODE : csUrl.PathEncode( );
>        break;
>      case URL_DECODE : csUrl.PathDecode( );
>        break;
>      case URL_CODE_AS_IS : ;
>        break;
>   }
>   return operator<<( csStream, (string&) csUrl);
>}
>
>
>//*****************************************************************************
>istream& operator>>(istream& csStream, UrlString& csUrl)
>{
>   operator>>( csStream, (string&) csUrl);
>
>   csUrl.check = 1;
>
>   switch( csUrl.urlcode )
>   {
>      case URL_ENCODE : csUrl.PathEncode( );
>        break;
>      case URL_DECODE : csUrl.PathDecode( );
>        break;
>      case URL_CODE_AS_IS : ;
>        break;
>   }
>   return csStream;
>}
>
>
>
>//*****************************************************************************
>void HexCharToInt( char hex, int &value )
>{
>   if( (hex >= '0') && (hex <= '9') )
>   {
>      value |= (hex - '0');
>   }
>   else
>   if( (hex >= 'a') && (hex <= 'f') )
>   {
>      value |= (hex - 'a' + 10);
>   }
>   else
>   if( (hex >= 'A') && (hex <= 'F') )
>   {
>      value |= (hex - 'A' + 10);
>   }
>   else
>   {
>      value = -1;
>   }
>}
>
>//*****************************************************************************
>int UrlEncode(char *source, size_t s_size, char *dest, size_t d_size )
>{
>   unsigned int cnt = 0;
>   int c;
>
>   if( source && dest && (s_size <= d_size) )
>   {
>      if( !s_size )
>      {
>         s_size = strlen( source );
>      }
>
>      while( s_size && *source && ( cnt < d_size ))
>      {
>         if( (( *source >= '0' ) && ( *source <= '9' )) ||
>             (( *source >= 'a' ) && ( *source <= 'z' )) ||
>             (( *source >= 'A' ) && ( *source <= 'Z' )) ||
>              ( *source == '/' ) || ( *source == '.' )  ||
>              ( *source == '_' )                           )
>         {
>            *dest = *source;
>         }
>         else
>         {
>            if( (cnt + 2) < d_size )
>            {
>               if( ( *source == '%' ) && ( s_size > 2 ))
>               {
>                  HexCharToInt( *(source+1), c = 0 );
>                  c = (c << 4) & 0xF0;
>                  HexCharToInt( *(source+2), c );
>                  if( c >= 0 )
>                  {
>                     source += 2;
>                     s_size -= 2;
>                  }
>                  else
>                  {
>                     c = '%';
>                  }
>               }
>               else
>               {
>                  c = *source;
>               }
>               *dest = '%';
>               dest++;
>               *dest = hex_char[(unsigned char)c >> 4];
>               dest++;
>               *dest = hex_char[(unsigned char)c & 0x0F];
>               cnt += 2;
>            }
>            else
>            {
>               return -1;
>            }
>         }
>         source++;
>         s_size--;
>
>         dest++;
>         cnt++;
>      }
>      if( cnt < d_size )
>      {
>         *dest = '\0';
>
>         return cnt;
>      }
>   }
>   return -1;
>}
>
>
>//*****************************************************************************
>int UrlDecode(char *source, size_t s_size, char *dest, size_t d_size )
>{
>   unsigned int cnt = 0;
>   int c;
>
>   if( source && dest && (s_size <= d_size) )
>   {
>      if( !s_size )
>      {
>         s_size = strlen( source );
>      }
>
>      while( s_size && *source && ( cnt < d_size ))
>      {
>         if( *source == '%' )
>         {
>            source++;
>            HexCharToInt( *(source), c = 0 );
>            c = (c << 4) & 0xF0;
>            HexCharToInt( *(source+1), c );
>            if( c >= 0 )
>            {
>               *dest = (char)c;
>               source += 2;
>               s_size -=2;
>            }
>            else
>            {
>               *dest = '%';
>               if( *source == '%' )
>               {
>                  source++;
>               }
>            }
>         }
>         else
>         {
>            *dest = *source;
>            source++;
>         }
>         s_size--;
>
>         dest++;
>
>         cnt++;
>      }
>      if( cnt < d_size )
>      {
>         *dest = '\0';
>      }
>      return cnt;
>   }
>   return -1;
>}
>
>//*****************************************************************************
>string &UrlDecode_s( string &str, size_t pos, size_t n )
>{
>   unsigned int size;
>   char *buffer;
>
>   size = str.size();
>   if( pos < size )
>   {
>      if( !n || ((pos + n) > size ))
>      {
>         n = size - pos;
>      }
>      buffer = (char *)str.c_str() + pos;
>      size = UrlDecode(buffer, n, buffer, n );
>      str.erase( pos + size, n - size);
>   }
>   return str;
>}
>
>//*****************************************************************************
>string &UrlEncode_s( string &str, size_t pos, size_t n )
>{
>
>   unsigned int size, b_size;
>   char *buffer;
>
>   size = str.size();
>   if( pos < size )
>   {
>      if( !n || ((pos + n) > size ))
>      {
>         n = size - pos;
>      }
>      b_size = n*3;
>      buffer = new char[b_size];
>      size = UrlEncode((char *)str.c_str() + pos, n, buffer, b_size );
>      str.replace( pos, n, buffer);
>      delete[] buffer;
>   }
>   return str;
>}
>
>
>#ifdef  CCXX_NAMESPACES
>}
>#endif
>
>
>
>
>------------------------------------------------------------------------
>
>// 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.
>
>//*****************************************************************************
>#ifndef CCXX_URL_STRING_H
>#define CCXX_URL_STRING_H
>
>#ifndef CCXX_CONFIG_H_
>#include <cc++/config.h>
>#endif
>
>#include "export.h"
>#include "socket.h"
>#include <string>
>#include <iostream>
>
>
>//*****************************************************************************
>#ifdef  CCXX_NAMESPACES
>namespace ost {
>#endif
>
>using namespace std;
>
>//*****************************************************************************
>/** @enum urlcode_t
>    Used to deside if the string should be decoded or encoded.
>    @see UrlString::urlcode
>  */
>enum urlcode_t { /// No modifications of the url.
>                 URL_CODE_AS_IS,
>                 /// Encode the url string, to send over a http stream
>                 URL_ENCODE,
>                 /// Decode the url string
>                 URL_DECODE };
>
>typedef enum urlcode_t urlcode_t;
>
>
>//*****************************************************************************
>class CCXX_CLASS_EXPORT UrlString;
>
>
>/// @see UrlString::operator<<
>ostream & operator<<(ostream & csStream, const UrlString& csUrl);
>/// @see UrlString::operator>>
>istream & operator>>(istream & csStream, UrlString& csUrl);
>
>
>//*****************************************************************************
>/** @class UrlString "url_class.h"
>    Set and get the parts of an url.
>    The following examples are supported :        \n
>    service://user@url:port/path?query+query      \n
>    service://url:port/path?query=1+query+query=2 \n
>    service://user@url/path                       \n
>    service://url:port                            \n
>    service://url                                 \n
>    url:port/path                                 \n
>    url                                           \n
>    user@url                                      \n
>    /path                                         \n
>    service:/path                                 \n
>    service:///path                               \n
>    @author arjan.paijralbe
>    @date   10-2-2002
> */
>class UrlString : protected string
>{
>   public :
>
>      /** Constructor of the class.
>          This constructor creates an empty class.
>          @param urlcode Sets the url coding for the stream operators.
>        */
>      UrlString( urlcode_t urlcode = URL_ENCODE );
>      /** Constructor of the class.
>          This constructor copy the url from the char buffer.
>          @param url Pointer to a char buffer with an url
>          @param urlcode Sets the url coding for the stream operators.
>        */
>      UrlString( char *url, urlcode_t urlcode = URL_ENCODE );
>      /** Constructor of the class.
>          This constructor copy the url from the string.
>          @param url Reference to a string with an url
>          @param urlcode Sets the url coding for the stream operators.
>        */
>      UrlString( string &url, urlcode_t urlcode = URL_ENCODE );
>      /** Constructor of the class.
>          This constructor copy the url from the UrlString.
>          @param url Reference to a string with an url
>        */
>      UrlString( UrlString &url );
>
>      /** Constructor of the class.
>          This constructor takes the the url from address.
>          @param address Contains the url.
>          @param urlcode sets the url coding for the stream operators.
>        */
>      UrlString( InetAddress &address, urlcode_t urlcode = URL_ENCODE );
>
>      /** Destructor of the class.
>        */
>      virtual ~UrlString( void );
>
>      /// This operator assign a new url to the class.
>      UrlString& operator=( char *url );
>      /// This operator assign a new url to the class.
>      UrlString& operator=( string &url );
>      /// This operator assign a new url to the class.
>      UrlString& operator=( UrlString &url );
>
>      /** This operator set a new coding mode of the class.
>          @see urlcode
>        */
>      UrlString& operator=( urlcode_t urlcode );
>
>      /** This operator compares the url the path and the port of
>          both classes for eaquality.
>          The service and the query will be ignored.
>        */
>      bool operator==( UrlString &url );
>
>      /** This operator compares the url the path both classes to find out
>          witch one is bigger....
>          The service the query and the port will be ignored.
>        */
>      bool operator>( UrlString &url );
>
>      /** This operator compares the url the path both classes to find out
>          witch one is smaller....
>          The service the query and the port will be ignored.
>        */
>      bool operator<( UrlString &url );
>
>
>      /// This methode assign a new url to the class.
>      UrlString& assign( char *url );
>      /// This methode assign a new url to the class.
>      UrlString& assign( UrlString &url );
>      /// This methode assign a new url to the class.
>      UrlString& assign( string &url );
>
>      /** This methode returns the specified service of the url.
>          If there is no service specified the buffer will be empty.
>          The service has no ':' char at the end!
>          @param buffer In this buffer the service is been inserted.
>          @param size Size of the buffer.
>          @retval buffer The service is been copyed.
>          @retval NULL Not enough space in the buffer.
>        */
>      char *GetService( char *buffer, size_t size );
>
>      /** This methode returns the specified service of the url.
>          If there is no service specified the buffer will be empty.
>          The service has no ':' char at the end!
>          @param str In this buffer the service is been inserted.
>          @return str.
>        */
>      string GetService( void );
>
>      /** This methode set the service of the url.
>          The should no ':' char at the end!
>          @param service Service to set.
>        */
>      void SetService( char *service );
>
>
>      /** This methode get the service from the urlstring class and set it this class.
>          @param service Service to set.
>        */
>      void SetService( UrlString &service );
>
>      /** This methode returns the specified user of the url.
>          If there is no user specified the buffer will be empty.
>          @param buffer In this buffer the user is been inserted.
>          @param size Size of the buffer.
>          @retval buffer The user is been copyed.
>          @retval NULL Not enough space in the buffer.
>
>        */
>      char *GetUser( char *buffer, size_t size );
>
>      /** This methode returns the specified user of the url.
>          If there is no user specified the buffer will be empty.
>          @param str In this buffer the user is been inserted.
>          @return str.
>        */
>      string GetUser( void );
>
>      /** This methode set the user of the url.
>          @param user User to set.
>
>        */
>      int SetUser( char *user );
>
>      /** This methode set the user of the url.
>          @param user User to set.
>
>        */
>      int SetUser( UrlString &user );
>
>
>      /** This methode erase the user from the url.
>        */
>      void EraseUser( void );
>
>      /** This methode returns the specified url.
>          If there is no url specified the buffer will be empty.
>          @param buffer In this buffer the url is been inserted.
>          @param size Size of the buffer.
>          @retval buffer The url is been copyed.
>          @retval NULL Not enough space in the buffer.
>        */
>      char *GetUrl( char *buffer, size_t size );
>
>      /** This methode returns the specified url.
>          If there is no url specified the buffer will be empty.
>          @param str In this buffer the url is been inserted.
>          @return str.
>        */
>      string GetUrl( void );
>
>      /** This methode set the url.
>          @param url Url to set.
>        */
>      void SetUrl( char *url );
>
>      /** This methode get the url from the urlstring class and set it to this class.
>          @param url Url to set.
>          @warning workes only if url contains an url!
>        */
>      void SetUrl( UrlString &url );
>
>      /** This methode takes the url from the address if it is a valid adress.
>          @param address Contains the address to the url.
>          @see InetAddress::getHostname
>        */
>      void SetUrl( InetAddress &address );
>
>      /** This methode insert the url to the InetAddress class.
>          @see InetAddress::operator=
>          @return address
>        */
>      InetAddress &GetAdresss( InetAddress &address );
>
>      /** This methode returns the specified path of the url.
>          If there is no path specified the buffer contains '/'.
>          @param buffer In this buffer the path is been inserted.
>          @param size Size of the buffer.
>          @retval buffer The path is been copyed.
>          @retval NULL Not enough space in the buffer.
>        */
>      char *GetPath( char *buffer, size_t size );
>
>      /** This methode returns the specified path of the url.
>          If there is no path specified the buffer contains '/'.
>          @param str In this buffer the path is been inserted.
>          @return str.
>        */
>      string GetPath( void );
>
>      /** This methode set the path of the url.
>          If the first char is not an '/' it will be added.
>          @param path Path to set.
>        */
>      void SetPath( char *path );
>
>      /** This methode takes the path from the urlstring class and add it to this class.
>          @param path Path to set.
>        */
>      void SetPath( UrlString &path );
>
>      /** This methode returns the specified query of the url.
>          If there is no query specified the buffer will be empty.
>          @param buffer In this buffer the query is been inserted.
>          @param size Size of the buffer.
>          @retval buffer The query is been copyed.
>          @retval NULL Not enough space in the buffer.
>        */
>      char *GetQuery( char *buffer, size_t size );
>
>      /** This methode returns the specified query of the url.
>          If there is no query specified the buffer will be empty.
>          @param str In this buffer the query is been inserted.
>          @return str.
>        */
>      string GetQuery( void );
>
>      /** This methode set the query of the url.
>          If the first char is not an '/' it will be added.
>          @param query Query to set.
>        */
>      int  SetQuery( char *query );
>
>
>      /** This methode get the query from the urlstring class and set it to this class.
>          If the first char is not an '/' it will be added.
>          @param query Query to set.
>        */
>      int  SetQuery( UrlString &query );
>
>      /// This methode erase the query from the url.
>      void EraseQuery( void );
>
>      /** This methode add's a new entry to the query.
>          The entry and the value will first encoded and then added to the url.
>          To seperate the entry's the '+' character is been used.
>          @param entry Name of the entry.
>          @arg entry = NULL No query will be added.
>          @param value Value of the entry.
>          @arg value = NULL only the entry will be added.
>         */
>      void AddQuery( char* entry, char * value );
>
>      /** This methode get the first query entry and decode it.
>          @param entry Buffer for the name of the entry.
>          @param e_size Size of the entry buffer.
>          @param value Buffer for the value of the entry.
>          @param v_size Size of the value buffer.
>          @retval 0 The first entry found.
>          @retval -1 No entry found or size of the buffer is to small.
>          @see NextQuery, AddQuery;
>         */
>      int FirstQuery( char* entry, size_t e_size, char * value, size_t v_size );
>
>      /** This methode get the first query entry and decode it.
>          @param entry Buffer for the name of the entry.
>          @param value Buffer for the value of the entry.
>          @retval 0 The first entry found.
>          @retval -1 No entry found.
>          @see NextQuery, AddQuery;
>         */
>
>      int FirstQuery( string &entry, string &value );
>
>      /** This methode get the next query entry and decode it.
>          @param entry Buffer for the name of the entry.
>          @param e_size Size of the entry buffer.
>          @param value Buffer for the value of the entry.
>          @param v_size Size of the value buffer.
>          @retval 0 The first entry found.
>          @retval -1 No entry found or size of the buffer is to small.
>          @see FirstQuery, AddQuery;
>         */
>      int NextQuery( char* entry, size_t e_size, char * value, size_t v_size );
>
>      /** This methode get the next query entry and decode it.
>          @param entry Buffer for the name of the entry.
>          @param value Buffer for the value of the entry.
>          @retval 0 The first entry found.
>          @retval -1 No entry found.
>          @see FirstQuery, AddQuery;
>         */
>      int NextQuery( string &entry, string &value );
>
>      /** Set the port number.
>          @warning only possible if a url is specified.
>        */
>      int Setport( unsigned int port );
>
>      /**  This returns the specified port.
>           If there is no port, the methode #service_to_port is been
>           called to translate the servic to a port number.
>           @retval 0..65535 specified port.
>           @retval -1 no port specified.
>         */
>      int GetPort( void );
>
>      /** Checks if there is a url specified.
>          @retval 0 It has a url.
>          @retval 1 There is no url, so it will be a local file.
>        */
>      int IsLocalFile( void );
>
>      /** Decode the path of the string.
>        */
>      void PathDecode( void );
>
>
>      /** Encode the path of the string.
>        */
>      void PathEncode( void );
>
>      /** Get the string as zero terminated char buffer.
>        */
>      const char * c_str( void );
>
>      /// Methode to stream the class.
>      friend ostream& operator<<(ostream& csStream, UrlString& csUrl);
>      /// Methode to get the url information from a stream.
>      friend istream& operator>>(istream& csStream, UrlString& csUrl);
>
>   protected :
>      /// End position of the service.
>      int service_end;
>      /// begin position of the user.
>      int user_begin;
>      /// end position of the user.
>      int user_end;
>      /// begin position of the url.
>      int url_begin;
>      /// end position of the url.
>      int url_end;
>      /// begin position of the path.
>      int path_begin;
>      /// end position of the path.
>      int path_end;
>      /// start position of the last readed query entry.
>      int query;
>
>      /** Is been used with the operator<< and operator>> to decide if the
>          path should be encoded or coded.
>          @see urlcode_t
>         */
>      urlcode_t urlcode;
>
>      /** Status of string modifications.
>          @arg check == 0 string is not modified.
>          @arg check != 0 string is modified, findpos should be called.
>        */
>      int check;
>
>      /** scanns the structure of the url and is updating the position
>          attributs of the class.
>        */
>      void findpos( void );
>
>      /** Translate the service to a port number.
>          Is been called by GetPort, if there is no port specified.
>          @retval 21 if service = 'ftp'
>          @retval 25 if service = 'smpt'
>          @retval 80 if service = 'http'
>          @retval -1 unknown service port.
>        */
>      virtual int service_to_port( void );
>
>      /** get the positions of the next qery entry.
>        */
>      inline int next_query_pos( int &entry_start, int &entry_end,
>                                 int &value_start, int &value_end );
>
>   private :
>      // prepeats the string to add a querry.
>      int prepeare_for_query( void );
>      inline int Cmp( size_type pos1, size_type n1,
>                            UrlString& str, size_type pos2, size_type n2);
>      inline int Cmp( size_type pos, size_type n, char *str );
>};
>
>//*****************************************************************************
>/** @defgroup global Global
> *  Global Functions and attributs.
> */
>
>/** Encode a string.
>    @param source  string to encode.
>    @param s_size  size of the encoded string.
>    @arg   s_size = 0 takes the size of the source string.
>    @arg   s_size > string size  it will takes the size of the source string
>    @arg   s_size < string size  it will takes s_size.
>    @param dest    buffer for the encoded string.
>    @param d_size  size of the buffer ( has to be 3 * s_size )
>    @retval 0 string is been encoded.
>    @retval -1 not enough space in the destination buffer.
>    @see #url_string.h
>    @ingroup global
>  */
>int UrlEncode( char *source, size_t s_size, char *dest, size_t d_size );
>
>/** Decode a string.
>    @param source  string to decode.
>    @param s_size  size of the decoded string.
>    @arg   s_size = 0 takes the size of the source string.
>    @arg   s_size > string size  it will takes the size of the source string
>    @arg   s_size < string size  it will takes s_size.
>    @param dest    buffer for the decoded string.
>    @param d_size  size of the buffer ( has to be at minimum s_size )
>    @retval 0 string is been encoded.
>    @retval -1 not enough space in the destination buffer.
>    @see #url_string.h
>    @ingroup global
>  */
>int UrlDecode( char *source, size_t s_size, char *dest, size_t d_size );
>
>/** Encode a string.
>    @param str  string to encode.
>    @param pos  start position to encode
>    @param n    size to encode.
>    @arg   n = 0 size from pos to end()
>    @return reference to str.
>    @see #url_string.h
>    @ingroup global
>  */
>string &UrlEncode_s( string &str, size_t pos = 0, size_t n = 0 );
>
>/** Decode a string.
>    @param str  string to encode.
>    @param pos  start position to encode
>    @param n    size to encode.
>    @arg   n = 0 size from pos to end()
>    @return reference to str.
>    @see #url_string.h
>    @ingroup global
>  */
>string &UrlDecode_s( string &str, size_t pos = 0, size_t n = 0 );
>
>#ifdef  CCXX_NAMESPACES
>}
>#endif
>
>#endif
>
>
>
>




From J.Shcultz@customdigital.ca Thu Feb 14 09:33:21 2002
Received: from optional.moshimoshi.co.jp ([211.7.137.130] helo=ptlmail)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16bMwl-0007sq-00; Thu, 14 Feb 2002 09:33:15 -0500
Date: Thu, 14 Feb 2002 23:33:03 +0900
From: "J.Shcultz@customdigital.ca" <J.Shcultz@customdigital.ca>
To: "7770@lycos.com" <7770@lycos.com>
Message-ID: <0981922261.0354079003@in3.magma.ca>
Subject: Why pay more for something if you don't have to?
MIME-Version: 1.0
Content-Type: text/html;
	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/>

<HTML><HEAD><TITLE>Take Control Of Your Conference Calls</TITLE>
<META http-equiv=3DContent-Type content=3D=22text/html; charset=3Dwindows-1=
252=22>
<META content=3D=22MSHTML 5.50.4134.600=22 name=3DGENERATOR></HEAD>
<BODY vLink=3D=23c0c0c0 link=3D=23c0c0c0 bgColor=3D=23FFFFFF leftMargin=3D0><F=
ONT 
face=3DTimes, New Roman>
<P>
<CENTER>
<TABLE width=3D600 border=3D0>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><B><FONT color=3D=23000066 size=3D6>Crystal Clear  
      Conference Calls<BR>Only <U>18 Cents</U> Per Minute=21</B></FONT><=
/TD></TR></TBODY></TABLE>
<P><FONT color=3D=23666600 size=3D5><B>(Anytime/Anywhere)</B></FONT> 
<P>
<TABLE width=3D350 border=3D0>
  <TBODY>
  <TR>
    <TD><FONT color=3D=23000066 size=3D3><B>
      <LI>No setup fees 
      <LI>No contracts or monthly fees 
      <LI>Call anytime, from anywhere, to anywhere 
      <LI>Connects up to 100 Participants 
      <LI>International Dial In 18 cents per minute
      <LI>Simplicity in set up and administration 
      <LI>Operator Help available 24/7 </B></FONT></LI></TD></TR></TBOD=
Y></TABLE>
<P>
<TABLE width=3D500 border=3D0>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><FONT color=3D=23666600 size=3D60><B><FONT size=3D5>G=
et the best 
      quality, the easiest to use, and lowest rate in the 
      industry.</B></FONT></FONT></TD></TR></TBODY></TABLE>
<P>
<TABLE width=3D400 border=3D0>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><FONT color=3D=23000066 size=3D4>If you like saving =
money, fill 
      out the form below and one of our consultants will contact 
  you.</FONT></TD></TR></TBODY></TABLE>
<P><FONT color=3D=23000066 size=3D2>Required Input Field<FONT color=3D=23666=
600 
size=3D2>*</FONT></FONT> 
<P>
<TABLE cellSpacing=3D0 borderColorDark=3D=23333300 cellPadding=3D3 width=3D6=
00 
borderColorLight=3D=23ffffcc>
  <TBODY>
  <TR>
    <TD align=3Dmiddle>
      <FORM action=3Dmailto:inbocks2_9=40yahoo.com?subject=3DConference_In=
quiry 
      method=3Dpost encType=3Dtext/plain>
      <TABLE width=3D=22100%=22>
        <TBODY>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066
          size=3D2>Name</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DNAME></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Web 
            Address</FONT></TD>
          <TD><INPUT value=3Dhttp:// name=3DURL></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Company 
            Name</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DCOMPANY_NAME></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>
            State</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT size=3D2 name=3DSTATE></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Business 
            Phone</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DBUS_PHONE></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Home 
            Phone</FONT></TD>
          <TD><INPUT name=3DHOME_PHONE></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Email 
            Address</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DEMAIL></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Type of 
            Business</FONT></TD>
          <TD><INPUT name=3DTYPE_OF_BUSINESS></TD></TR></TBODY></TABLE>
      <P><INPUT type=3Dsubmit value=3D=22Submit Information=22 name=3Dsubmit=
> 
    </FORM></P></TD></TR></TBODY></TABLE>
<BR><BR>
<TABLE width=3D500>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><FONT face=3D=22Arial, Helvetica, sans-serif=22 colo=
r=3D=23666600
      size=3D1>c 1999-2002 CCFL <BR> To be removed from our distribution=
 lists, please  
      <A href=3D=22mailto:delete6_4=40yahoo.com?subject=3DRemove_Conferenci=
ng=22>Click 
      here.<FONT color=3D=23666600></A></FONT>.</FONT></TD></TR></TBODY><=
/TABLE></P></CENTER></BODY></HTML>

*****


From apavloff@eason.com Thu Feb 14 13:42:47 2002
Received: from post.ap.net ([192.82.0.14])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16bQqF-0006jt-00
	for <bug-commoncpp@gnu.org>; Thu, 14 Feb 2002 13:42:47 -0500
Received: from mailman.eason.com (rtr-192-82-16-61.wireless.ap.net [192.82.16.61] (may be forged))
	by post.ap.net (8.12.1/8.12.1) with ESMTP id g1EIegxJ004360
	for <bug-commoncpp@gnu.org>; Thu, 14 Feb 2002 10:40:47 -0800 (PST)
Received: by mailman.eason.com with Internet Mail Service (5.5.2653.19)
	id <1YP9Z4WG>; Thu, 14 Feb 2002 10:39:22 -0800
Message-ID: <D3AF5F134D627243993F2F2FC32EE4D2997F@mailman.eason.com>
From: Alex Pavloff <apavloff@eason.com>
To: bug-commoncpp@gnu.org
Subject: Unix domain sockets patch
Date: Thu, 14 Feb 2002 10:39:18 -0800
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2653.19)
Content-Type: multipart/mixed;
	boundary="----_=_NextPart_000_01C1B586.E9135D10"
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_01C1B586.E9135D10
Content-Type: text/plain;
	charset="iso-8859-1"


Hello folks.

Attached is a patch that adds Unix Domain sockets, streams and sessions in
the style of the TCP sockets, streams, and sessions.  

I may have put my name in as the author, but the code is a direct rip from
the TCP code.  In fact, there's a lot of duplicated code, and I wonder if
there wouldn't be some way to combine this code.

Please let me know what you think.

Alex Pavloff
Software Engineer
Eason Technology 


------_=_NextPart_000_01C1B586.E9135D10
Content-Type: application/octet-stream;
	name="unixdomain.patch"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="unixdomain.patch"

*** oldCommonC++-1.9.5/src/socket.h	Thu Jan  3 15:24:04 2002
--- CommonC++-1.9.5/src/socket.h	Tue Feb  5 15:12:31 2002
***************
*** 1733,1738 ****
--- 1733,2072 ----
  	 * @param stack allocation needed on some platforms.
  	 */
  	TCPSession(TCPSocket &server, int size =3D 512,
+ 		   int pri =3D 0, int stack =3D 0);
+ };
+=20
+=20
+ /**
+  * Unix domain sockets are used for stream based connected sessions =
between
+  * processes on the same machine.
+=20
+  * An implicit and unique UnixSocket object exists in Common C++ to =
represent
+  * a bound Unix domain socket acting as a "server" for receiving =
connection requests.
+  * This class is not part of UnixStream because such objects normally =
perform
+  * no physical I/O (read or write operations) other than to specify a =
listen
+  * backlog queue and perform "accept" operations for pending =
connections.
+  *
+  * @author Alex Pavloff <alex@pavloff.net>
+  * @short bound server for Unix domain streams and sessions.
+  */
+ class UnixSocket : protected Socket
+ {
+ protected:
+ 	friend class UnixStream;
+ 	friend class SocketPort;
+ 	friend class unixstream;
+=20
+ public:
+ 	/**
+ 	 * A Unix domain "server" is created as a Unix domain socket that is =
bound
+ 	 * to a pathname and that has a backlog queue to listen for =
connection
+ 	 * requests.  If the server cannot be created, an exception is =
thrown.
+ 	 *
+ 	 * @param pathname pathname to socket file
+ 	 * @param backlog size of connection request queue.
+ 	 */
+ 	UnixSocket(const char* pathname, int backlog =3D 5);
+=20
+ 	/**
+ 	 * Used to wait for pending connection requests.
+ 	 */
+ 	inline bool isPendingConnection(timeout_t timeout =3D TIMEOUT_INF) =
/** not const -- jfc */
+ 		{return Socket::isPending(SOCKET_PENDING_INPUT, timeout);}
+=20
+ 	/**
+ 	 * Use base socket handler for ending this socket.
+ 	 */
+ 	virtual ~UnixSocket()
+ 		{endSocket();};
+ };
+=20
+ /**
+  * Unix streams are used to represent Unix domain client connections =
to a
+  * local server for accepting client connections.  The Unix
+  * stream is a C++ "stream" class, and can accept streaming of data =
to
+  * and from other C++ objects using the << and >> operators.
+  *
+  * Unix Stream itself can be formed either by connecting to a bound =
network
+  * address of a Unix domain server, or can be created when =
"accepting" a
+  * network connection from a Unix domain server.
+  *
+  * @author Alex Pavloff <alex@pavloff.net>
+  * @short streamable Unix domain socket connection.
+  */
+ class UnixStream : public Socket, public std::streambuf, public =
std::iostream
+ {
+ private:
+ 	int doallocate();
+=20
+ protected:
+ 	timeout_t timeout;
+ 	int bufsize;
+ 	char *gbuf, *pbuf;
+=20
+ 	/**
+ 	 * The constructor required for "unixstream", a more C++ style
+ 	 * version of the TCPStream class.
+ 	 */
+ 	UnixStream(bool throwflag =3D true);
+=20
+ 	/**
+ 	 * Used to allocate the buffer space needed for iostream
+ 	 * operations.  This function is called by the constructor.
+ 	 *
+ 	 * @param size of stream buffers from constructor.
+ 	 */
+ 	void Allocate(int size);
+=20
+ 	/**
+ 	 * Used to terminate the buffer space and cleanup the socket
+ 	 * connection.  This fucntion is called by the destructor.
+ 	 */
+ 	void endStream(void);
+=20
+ 	/**
+ 	 * This streambuf method is used to load the input buffer
+ 	 * through the established unix domain socket connection.
+ 	 *
+ 	 * @return char from get buffer, EOF if not connected.
+ 	 */
+ 	virtual int underflow(void);
+=20
+ 	/**
+ 	 * This streambuf method is used for doing unbuffered reads
+ 	 * through the established unix domain socket connection when in =
interactive mode.
+ 	 * Also this method will handle proper use of buffers if not in
+ 	 * interative mode.
+ 	 *
+ 	 * @return char from unix domain socket connection, EOF if not =
connected.
+ 	 */
+ 	int uflow(void);
+=20
+ 	/**
+ 	 * This streambuf method is used to write the output
+ 	 * buffer through the established unix domain connection.
+ 	 *
+ 	 * @param char to push through.
+ 	 * @return char pushed through.
+ 	 */
+ 	int overflow(int ch);
+=20
+ 	/**
+ 	 * Create a Unix domain stream by connecting to a Unix domain socket
+ 	 *
+ 	 * @param pathname path to socket
+ 	 * @param size of streaming input and output buffers.
+ 	 */
+ 	void Connect(const char* pathname, int size);
+=20
+ 	/**
+ 	 * Used in derived classes to refer to the current object via
+ 	 * it's iostream.  For example, to send a set of characters
+ 	 * in a derived method, one might use *tcp() << "test".
+ 	 *
+ 	 * @return stream pointer of this object.
+ 	 */
+ 	std::iostream *unixstr(void)
+ 		{return ((std::iostream *)this);};
+=20
+ public:
+ 	/**
+ 	 * Create a Unix domain stream by accepting a connection from a =
bound
+ 	 * Unix domain socket acting as a server.  This performs an "accept"
+ 	 * call.
+ 	 *
+ 	 * @param size of streaming input and output buffers.
+ 	 * @param flag to throw errors.
+ 	 * @param timeout for all operations.
+ 	 */
+ 	UnixStream(UnixSocket &server, int size =3D 512, bool throwflag =3D =
true, timeout_t timeout =3D 0);
+=20
+ 	/**
+ 	 * Create a Unix domain stream by connecting to a Unix domain socket
+ 	 *
+ 	 * @param pathname path to socket
+ 	 * @param size of streaming input and output buffers.
+ 	 * @param flag to throw errors.
+ 	 * @param timeout for all operations.
+ 	 */
+ 	UnixStream(const char* pathname, int size =3D 512, bool throwflag =
=3D true, timeout_t to =3D 0);
+=20
+ 	/**
+ 	 * Set the I/O operation timeout for socket I/O operations.
+ 	 *
+ 	 * @param timeout to set.
+ 	 */
+ 	inline void setTimeout(timeout_t to)
+ 		{timeout =3D to;};
+=20
+ 	/**
+ 	 * A copy constructor creates a new stream buffer.
+ 	 *
+ 	 * @param source of copy.
+ 	 *
+ 	 */
+ 	UnixStream(const UnixStream &source);
+=20
+ 	/**
+ 	 * Flush and empty all buffers, and then remove the allocated
+ 	 * buffers.
+ 	 */
+ 	virtual ~UnixStream()
+ 		{endStream();};
+=20
+ 	/**
+ 	 * Flushes the stream input and output buffers, writes
+ 	 * pending output.
+ 	 *
+ 	 * @return 0 on success.
+ 	 */
+ 	int sync(void);
+=20
+ 	/**
+ 	 * Get the status of pending stream data.  This can be used to
+ 	 * examine if input or output is waiting, or if an error or
+ 	 * disconnect has occured on the stream.  If a read buffer
+ 	 * contains data then input is ready and if write buffer
+ 	 * contains data it is first flushed and then checked.
+ 	 */
+ 	bool isPending(sockpend_t pend, timeout_t timeout =3D TIMEOUT_INF);
+=20
+ 	/**
+ 	 * Return the size of the current stream buffering used.
+ 	 *
+ 	 * @return size of stream buffers.
+ 	 */
+ 	int getBufferSize(void) const
+ 		{return bufsize;};
+ };
+=20
+ /**
+  * A more natural C++ "unixstream" class for use by non-threaded
+  * applications.  This class behaves a lot more like fstream and
+  * similar classes.
+  *
+  * @author Alex Pavloff <alex@pavloff.net>
+  * @short C++ "fstream" style unixstream class.
+  */
+ class unixstream : public UnixStream
+ {
+ public:
+ 	/**
+ 	 * Construct an unopened "tcpstream" object.
+ 	 */
+ 	unixstream();
+=20
+ 	/**
+ 	 * Construct and "open" (connect) the tcp stream to a remote
+ 	 * socket.
+ 	 *
+ 	 * @param pathname pathname to socket file
+ 	 * @param buffer size for streaming (optional).
+ 	 */
+ 	unixstream(const char *pathname, int buffer =3D 512);
+=20
+ 	/**
+ 	 * Construct and "accept" (connect) the tcp stream through
+ 	 * a server.
+ 	 *
+ 	 * @param unixsock socket to accept from.
+ 	 * @param buffer size for streaming (optional).
+ 	 */
+ 	unixstream(UnixSocket &unixsock, int buffer =3D 512);
+=20
+ 	/**
+ 	 * Open a tcp stream connection.  This will close the currently
+ 	 * active connection first.
+ 	 *
+ 	 * @param pathname pathname to socket file
+ 	 * @param buffer size for streaming (optional)
+ 	 */
+ 	void open(const char *pathname, int buffer =3D 512)
+ 		{ UnixStream::Connect( pathname, buffer ); }
+=20
+ 	/**
+ 	 * Open a tcp stream connection by accepting a tcp socket.
+ 	 *
+ 	 * @param unixsock socket to accept from.
+ 	 * @param buffer size for streaming (optional)
+ 	 */
+ 	void open(UnixSocket &unixsock, int buffer =3D 512);
+=20
+ 	/**
+ 	 * Close the active tcp stream connection.
+ 	 */
+ 	void close(void);
+=20
+ 	/**
+ 	 * Test to see if stream is open.
+ 	 */
+ 	bool operator!() const;
+ };
+=20
+ /**
+  * The Unix domain session is used to primarily to represent a client =
connection
+  * that can be managed on a seperate thread.  The Unix domain session =
also supports
+  * a non-blocking connection scheme which prevents blocking during =
the
+  * constructor and moving the process of completing a connection into =
the
+  * thread that executes for the session.
+  *
+  * @author Alex Pavloff <alex@pavloff.net>
+  * @short Threaded streamable unix domain socket with non-blocking =
constructor.
+  */
+ class UnixSession : public UnixStream, public Thread
+ {
+ protected:
+ 	/**
+ 	 * Normally called during the thread Initial() method by default,
+ 	 * this will wait for the socket connection to complete when
+ 	 * connecting to a remote socket.  One might wish to use
+ 	 * setCompletion() to change the socket back to blocking I/O
+ 	 * calls after the connection completes.  To implement the
+ 	 * session one must create a derived class which implements
+ 	 * Run().
+ 	 *
+ 	 * @return 0 if successful, -1 if timed out.
+ 	 * @param timeout to wait for completion in milliseconds.
+ 	 */
+ 	int WaitConnection(timeout_t timeout =3D TIMEOUT_INF);
+=20
+ 	/**
+ 	 * The initial method is used to esablish a connection when
+ 	 * delayed completion is used.  This assures the constructor
+ 	 * terminates without having to wait for a connection request
+ 	 * to complete.
+ 	 */
+ 	CCXX_MEMBER(void) Initial(void);
+=20
+ 	/**
+ 	 * UnixSession derived objects can be freely created with "new"
+ 	 * and safely terminate their "Run" method on their own by
+ 	 * self-deleting when the thread terminates.
+ 	 */
+ 	CCXX_MEMBER(void) Final(void)
+ 		{delete this;};
+ public:
+ 	/**
+ 	 * Create a Unix domain socket that will be connected to a local =
server
+ 	 * server and that will execute under it's own thread.
+ 	 *
+ 	 * @param pathname path to socket
+ 	 * @param size of streaming buffer.
+ 	 * @param pri execution priority relative to parent.
+ 	 * @param stack allocation needed on some platforms.
+ 	 */
+ 	UnixSession(const char* pathname, int size =3D 512, int pri =3D 0, =
int stack =3D 0);
+=20
+ 	/**
+ 	 * Create a Unix domain socket from a bound Unix domain server by =
accepting a pending
+ 	 * connection from that server and execute a thread for the accepted =
connection.
+ 	 *
+ 	 * @param server unix domain socket to accept a connection from.
+ 	 * @param size of streaming buffer.
+ 	 * @param pri execution priority relative to parent.
+ 	 * @param stack allocation needed on some platforms.
+ 	 */
+ 	UnixSession(UnixSocket &server, int size =3D 512,
  		   int pri =3D 0, int stack =3D 0);
  };
 =20
*** oldCommonC++-1.9.5/src/socket.cpp	Wed Jan 23 06:38:57 2002
--- CommonC++-1.9.5/src/socket.cpp	Wed Feb  6 10:52:13 2002
***************
*** 1352,1357 ****
--- 1353,1803 ----
  	if(WaitConnection(60000))
  		Exit();
  }
+=20
+ UnixSocket::UnixSocket(const char* pathname, int backlog) :
+ Socket(AF_UNIX, SOCK_STREAM, 0)
+ {
+ 	struct sockaddr_un addr;
+ 	memset(&addr, 0, sizeof(addr));
+ 	addr.sun_family =3D AF_UNIX;
+ 	strncpy( addr.sun_path, pathname, sizeof(addr.sun_path) );
+=20
+ #ifdef	SO_REUSEADDR
+ 	int opt =3D 1;
+ 	setsockopt(so, SOL_SOCKET, SO_REUSEADDR, (char *)&opt, =
(socklen_t)sizeof(opt));
+ #endif
+ 	if(bind(so, (struct sockaddr *)&addr, sizeof(addr.sun_family) + =
strlen(addr.sun_path) ))
+ 	{
+ 		endSocket();
+ 		Error(SOCKET_BINDING_FAILED);
+ 		return;
+ 	}
+=20
+ 	if(listen(so, backlog))
+ 	{
+ 		endSocket();
+ 		Error(SOCKET_BINDING_FAILED);
+ 		return;
+ 	}
+ 	state =3D SOCKET_BOUND;
+ }
+=20
+ UnixStream::UnixStream(UnixSocket &server, int size, bool throwflag, =
timeout_t to) :
+ 	Socket(accept(server.so, NULL, NULL))
+ 	,streambuf()
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	,iostream()
+ #else
+ 	,iostream((streambuf *)this)
+ #endif
+ 	,bufsize(0)
+ 	,gbuf(NULL)
+ 	,pbuf(NULL)
+ {
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	init((streambuf *)this);
+ #endif
+=20
+ 	timeout =3D to;
+ 	setError(throwflag);
+=20
+ 	Allocate(size);
+ 	Socket::state =3D SOCKET_CONNECTED;
+ }
+=20
+ UnixStream::UnixStream(const char* pathname, int size, bool =
throwflag, timeout_t to) :
+ 	Socket(AF_UNIX, SOCK_STREAM, 0),
+ 	streambuf(),
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	iostream(),
+ #else
+         iostream((streambuf *)this),
+ #endif
+ 	bufsize(0),gbuf(NULL),pbuf(NULL)
+ {
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	init((streambuf *)this);
+ #endif
+ 	timeout =3D to;
+ 	setError(throwflag);
+ 	Connect(pathname, size);
+ }
+=20
+ void UnixStream::Connect(const char* pathname, int size)
+ {
+ 	struct sockaddr_un addr;
+ 	memset(&addr, 0, sizeof(addr));
+ 	addr.sun_family =3D AF_UNIX;
+ 	strncpy( addr.sun_path, pathname, sizeof(addr.sun_path) );
+=20
+ 	if(connect(so, (struct sockaddr *)&addr, =
(socklen_t)sizeof(addr.sun_family) + strlen(addr.sun_path) ) !=3D 0)
+ 	{
+ 		connectError();
+ 		endSocket();
+ 		return;
+ 	}
+=20
+ 	Allocate(size);
+ 	Socket::state =3D SOCKET_CONNECTED;
+ }
+=20
+ UnixStream::UnixStream(bool throwflag) :
+ 	Socket(PF_UNIX, SOCK_STREAM, 0),
+ 	streambuf(),
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	iostream(),
+ #else
+         iostream((streambuf *)this),
+ #endif
+         bufsize(0),gbuf(NULL),pbuf(NULL),
+         timeout(0)
+ {
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	init((streambuf *)this);
+ #endif
+ 	setError(throwflag);
+ }
+=20
+ UnixStream::UnixStream(const UnixStream &source) :
+ Socket(dup(source.so)), streambuf(),
+ #ifdef	HAVE_OLD_IOSTREAM
+ iostream()
+ #else
+ iostream((streambuf *)this)
+ #endif
+ {
+ #ifdef	HAVE_OLD_IOSTREAM
+ 	init((streambuf *)this);
+ #endif
+ 	bufsize =3D source.bufsize;
+ 	Allocate(bufsize);
+ }
+=20
+ void UnixStream::endStream(void)
+ {
+ 	if(bufsize) sync();
+ 	delete [] gbuf;
+ 	delete [] pbuf;
+ 	gbuf =3D pbuf =3D NULL;
+ 	bufsize =3D 0;
+ 	endSocket();
+ }
+=20
+ void UnixStream::Allocate(int size)
+ {
+ 	if(size < 2)
+ 	{
+ 		gbuf =3D pbuf =3D NULL;
+ 		bufsize =3D 1;
+ 		return;
+ 	}
+=20
+ 	gbuf =3D new char[size];
+ 	pbuf =3D new char[size];
+ 	if(!pbuf || !gbuf)
+ 	{
+ 		Error(SOCKET_RESOURCE_FAILURE);
+ 		return;
+ 	}
+ 	bufsize =3D size;
+ 	clear();
+=20
+ #if (defined(__GNUC__) && (__GNUC__ < 3)) && !defined(WIN32)
+ 	setb(gbuf, gbuf + size, 0);
+ #endif
+ 	setg(gbuf, gbuf + size, gbuf + size);
+ 	setp(pbuf, pbuf + size);
+ }
+=20
+ int UnixStream::doallocate()
+ {
+ 	if(bufsize)
+ 		return 0;
+=20
+ 	Allocate(1);
+ 	return 1;
+ }
+=20
+ int UnixStream::uflow(void)
+ {
+ 	int ret =3D underflow();
+=20
+ 	if (ret =3D=3D EOF)
+ 		return EOF;
+=20
+ 	if (bufsize !=3D 1)
+ 		gbump(1);
+=20
+ 	return ret;
+ }
+=20
+ int UnixStream::underflow(void)
+ {
+ 	int rlen =3D 1;
+ 	unsigned char ch;
+=20
+ 	if(bufsize =3D=3D 1)
+ 	{
+ 		if(Socket::state =3D=3D SOCKET_STREAM)
+ 			rlen =3D ::read(so, (char *)&ch, 1);
+ 		else if(timeout && !Socket::isPending(SOCKET_PENDING_INPUT, =
timeout))
+         {
+             clear(ios::failbit | rdstate());
+             Error(SOCKET_TIMEOUT_ERROR);
+             return EOF;
+ 		}
+ 		else
+ 			rlen =3D ::recv(so, (char *)&ch, 1, 0);
+ 		if(rlen < 1)
+ 		{
+ 			if(rlen < 0)
+ 			{
+ 				clear(ios::failbit | rdstate());
+ 				Error(SOCKET_INPUT_ERROR);
+ 			}
+ 			return EOF;
+ 		}
+ 		return ch;
+ 	}
+=20
+ 	if(!gptr())
+ 		return EOF;
+=20
+ 	if(gptr() < egptr())
+ 		return (unsigned char)*gptr();
+=20
+ 	rlen =3D (gbuf + bufsize) - eback();
+ 	if(Socket::state =3D=3D SOCKET_STREAM)
+ 		rlen =3D ::read(so, (char *)eback(), rlen);
+ 	else if(timeout && !Socket::isPending(SOCKET_PENDING_INPUT, =
timeout))
+ 	{
+ 		clear(ios::failbit | rdstate());
+ 		Error(SOCKET_TIMEOUT_ERROR);
+ 		return EOF;
+ 	}
+ 	else
+ 		rlen =3D ::recv(so, (char *)eback(), rlen, 0);
+ 	if(rlen < 1)
+ 	{
+ 		if(rlen < 0)
+ 		{
+ 			clear(ios::failbit | rdstate());
+ 			Error(SOCKET_INPUT_ERROR);
+ 		}
+ 		return EOF;
+ 	}
+=20
+ 	setg(eback(), eback(), eback() + rlen);
+ 	return (unsigned char) *gptr();
+ }
+=20
+ bool UnixStream::isPending(sockpend_t pending, timeout_t timeout)
+ {
+ 	if(pending =3D=3D SOCKET_PENDING_INPUT && in_avail())
+ 		return true;
+ 	else if(pending =3D=3D SOCKET_PENDING_OUTPUT)
+ 		flush();
+=20
+ 	return Socket::isPending(pending, timeout);
+ }
+=20
+ int UnixStream::sync(void)
+ {
+ 	overflow(EOF);
+ 	setg(gbuf, gbuf + bufsize, gbuf + bufsize);
+ 	return 0;
+ }
+=20
+ int UnixStream::overflow(int c)
+ {
+ 	unsigned char ch;
+ 	int rlen, req;
+=20
+ 	if(bufsize =3D=3D 1)
+ 	{
+ 		if(c =3D=3D EOF)
+ 			return 0;
+=20
+ 		ch =3D (unsigned char)(c);
+ 		if(Socket::state =3D=3D SOCKET_STREAM)
+ 			rlen =3D ::write(so, (const char *)&ch, 1);
+ 		else
+ 			rlen =3D ::send(so, (const char *)&ch, 1, 0);
+ 		if(rlen < 1)
+ 		{
+ 			if(rlen < 0)
+ 			{
+ 				clear(ios::failbit | rdstate());
+ 				Error(SOCKET_OUTPUT_ERROR);
+ 			}
+ 			return EOF;
+ 		}
+ 		else
+ 			return c;
+ 	}
+=20
+ 	if(!pbase())
+ 		return EOF;
+=20
+ 	req =3D pptr() - pbase();
+ 	if(req)
+ 	{
+ 		if(Socket::state =3D=3D SOCKET_STREAM)
+ 			rlen =3D ::write(so, (const char *)pbase(), req);
+ 		else
+ 			rlen =3D ::send(so, (const char *)pbase(), req, 0);
+ 		if(rlen < 1)
+ 		{
+ 			if(rlen < 0)
+ 			{
+ 				clear(ios::failbit | rdstate());
+ 				Error(SOCKET_OUTPUT_ERROR);
+ 			}
+ 			return EOF;
+ 		}
+ 		req -=3D rlen;
+ 	}
+=20
+ 	// if write "partial", rebuffer remainder
+=20
+ 	if(req)
+ 		memcpy(pptr(), pptr() + rlen, req);
+ 	setp(pbuf + req, pbuf + bufsize);
+=20
+ 	if(c !=3D EOF)
+ 	{
+ 		*pptr() =3D (unsigned char)c;
+ 		pbump(1);
+ 	}
+ 	return c;
+ }
+=20
+ unixstream::unixstream() :
+ UnixStream()
+ {
+ 	setError(false);	/* no exceptions */
+ }
+=20
+ unixstream::unixstream(const char *pathname, int buf) :
+ UnixStream()
+ {
+ 	setError(false);
+ 	open(pathname, buf);
+ }
+=20
+ unixstream::unixstream(UnixSocket &server, int buf) :
+ UnixStream()
+ {
+ 	setError(false);
+ 	open(server, buf);
+ }
+=20
+ bool unixstream::operator!() const
+ {
+ 	return (Socket::state !=3D SOCKET_CONNECTED) ? true : false;
+ }
+=20
+ void unixstream::open(UnixSocket &unixsock, int buf)
+ {
+ 	endStream();
+ 	so =3D accept(unixsock.so, NULL, NULL);
+ 	if(so =3D=3D INVALID_SOCKET)
+ 		return;
+=20
+ 	Allocate(buf);
+ 	Socket::state =3D SOCKET_CONNECTED;
+ }
+=20
+ void unixstream::close(void)
+ {
+ 	if(Socket::state =3D=3D SOCKET_AVAILABLE)
+ 		return;
+=20
+ 	endStream();
+ 	so =3D socket(AF_UNIX, SOCK_STREAM, 0);
+ 	if(so !=3D INVALID_SOCKET)
+ 		Socket::state =3D SOCKET_AVAILABLE;
+ }
+=20
+ UnixSession::UnixSession(const char* pathname, int size, int pri, int =
stack) :
+ UnixStream(), Thread(pri, stack)
+ {
+ 	setCompletion(false);
+ 	setError(false);
+ 	Allocate(size);
+=20
+ 	struct sockaddr_un addr;
+ 	memset(&addr, 0, sizeof(addr));
+ 	addr.sun_family =3D AF_UNIX;
+ 	strncpy( addr.sun_path, pathname, sizeof(addr.sun_path) );
+=20
+ 	if(connect(so, (struct sockaddr *)&addr, =
(socklen_t)sizeof(addr.sun_family) + strlen(addr.sun_path) ) !=3D 0)
+ 	{
+ #ifdef WIN32
+ 		if( WSAGetLastError() =3D=3D WAEISCONN )
+ #else
+ 		if( errno =3D EINPROGRESS )
+ #endif
+ 		{
+ 			Socket::state =3D SOCKET_CONNECTING;
+ 		}
+ 		else
+ 		{
+ 			endSocket();
+ 			Socket::state =3D SOCKET_INITIAL;
+ 		}
+ 		return;
+ 	}
+=20
+ 	setCompletion(true);
+ 	Socket::state =3D SOCKET_CONNECTED;
+ }
+=20
+=20
+ UnixSession::UnixSession(UnixSocket &s,int size, int pri, int stack) =
:
+ UnixStream(s, size), Thread(pri, stack)
+ {
+ 	setCompletion(true);
+ 	setError(false);
+ }
+=20
+ int UnixSession::WaitConnection(timeout_t timeout)
+ {
+ 	long sockopt =3D 0;
+ 	socklen_t len =3D sizeof(sockopt);
+=20
+ 	switch(Socket::state)
+ 	{
+ 	case SOCKET_INITIAL:
+ 		return -1;
+ 	case SOCKET_CONNECTED:
+ 		break;
+ 	case SOCKET_CONNECTING:
+ 		if(!Socket::isPending(SOCKET_PENDING_OUTPUT, timeout))
+ 		{
+ 			endSocket();
+ 			Socket::state =3D SOCKET_INITIAL;
+ 			return -1;
+ 		}
+=20
+ 		getsockopt(so, SOL_SOCKET, SO_ERROR, (char *)&sockopt, &len);
+ 		if(sockopt)
+ 		{
+ 			endSocket();
+ 			Socket::state =3D SOCKET_INITIAL;
+ 			return -1;
+ 		}
+ 	}
+ 	Socket::state =3D SOCKET_CONNECTED;
+ 	return 0;
+ }
+=20
+ void UnixSession::Initial(void)
+ {
+ 	if(WaitConnection(60000))
+ 		Exit();
+ }
+=20
 =20
  CCXX_EXPORT(ostream&) operator<<(ostream &os, const InetAddress &ia)
  {

------_=_NextPart_000_01C1B586.E9135D10--


From sherry@dbtrigger.com Sun Feb 17 15:43:22 2002
Received: from femail37.sdc1.sfba.home.com ([24.254.60.31])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16cY9a-0003w3-00
	for <bug-commoncpp@gnu.org>; Sun, 17 Feb 2002 15:43:22 -0500
Received: from dbtrigger.com ([68.58.131.19])
          by femail37.sdc1.sfba.home.com
          (InterMail vM.4.01.03.20 201-229-121-120-20010223) with ESMTP
          id <20020217204320.OMUP27272.femail37.sdc1.sfba.home.com@dbtrigger.com>
          for <bug-commoncpp@gnu.org>; Sun, 17 Feb 2002 12:43:20 -0800
Date: Sun, 17 Feb 2002 15:39:45 -0500
From: "sherry@dbtrigger.com" <sherry@dbtrigger.com>
To: "bug-commoncpp@gnu.org" <bug-commoncpp@gnu.org>
Reply-to: <sherry@dbtrigger.com>
Subject: Send eMail Alerts from Any Application with dbTrigger
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: 
X-Mailer: vbSendMail 3.0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
Message-Id: <20020217204320.OMUP27272.femail37.sdc1.sfba.home.com@dbtrigger.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/>

<html>
<head>
<title>.: dbTrigger - Real Time Data Mining :.</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
.content {  font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; font-style: normal; font-weight: normal; color: #333333; text-decoration: none}
.links {  color: #78A5D1; text-decoration: underline}
-->
</style>
</head>

<body text="#333333" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" background="http://www.dbtrigger.com/newsletter/images/bg.gif" bgcolor="#92B6DB" link="#333333" vlink="#333333" alink="#333333">
<div align="center">
<table width="625" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr>
      <td align="left" valign="top"><img src="http://www.dbtrigger.com/newsletter/images/top.gif" width="625" height="49"></td>
  </tr>
</table>
  <table width="625" border="0" cellspacing="0" cellpadding="0">
    <tr align="left" valign="top"> 
      <td width="13" background="http://www.dbtrigger.com/newsletter/images/bg_left.gif"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="13" height="1"></td>
      <td width="597" bgcolor="#FFFFFF"> 
        <table width="597" border="0" cellspacing="0" cellpadding="0">
          <tr align="left" valign="top"> 
            <td width="177" align="right"><img src="http://www.dbtrigger.com/newsletter/images/logo.gif" width="150" height="53" vspace="6" usemap="#Map" border="0"></td>
            <td width="281">&nbsp;</td>
            <td width="139" valign="middle"><img src="http://www.dbtrigger.com/newsletter/images/realtime.gif" width="126" height="15"></td>
          </tr>
        </table>
        <table width="597" border="0" cellspacing="0" cellpadding="0">
          <tr align="left" valign="top"> 
            <td width="24" align="left"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="24" height="1"></td>
            <td width="272" class="content"><img src="http://www.dbtrigger.com/newsletter/images/square.gif" width="12" height="20"><br><img src="http://www.dbtrigger.com/newsletter/images/t_talk3.gif" width="199" height="15"><br>
              Today's business applications provide a <br>
              wealth of information. Unfortunately, <br>
              they rarely are fully utilized and generally <br>
              fall short of communicating critical events. <br>
              <br>
              Now imagine, your application talking back <br>
              to you; keeping you abreast of events, as <br>
              they occur, anytime, anywhere.<br>
              <img src="http://www.dbtrigger.com/newsletter/images/t_dbtriggercan.gif" width="110" height="16" vspace="5"> 
              <br>
            </td>
            <td width="301" valign="top" align="right"><img src="http://www.dbtrigger.com/newsletter/images/i_tailored.gif" width="300" height="142" usemap="#MapMap" border="0"> 
              <map name="MapMap"> 
                <area shape="rect" coords="3,2,296,139" href="http://www.dbtrigger.com" alt="www.dbtrigger.com" title="www.dbtrigger.com" target="_blank">
              </map>
            </td>
          </tr>
          <tr align="left" valign="top"> 
            <td width="24" align="left">&nbsp;</td>
            <td colspan="2" class="content">Whether it's notifying sales of incoming 
              web orders, alerting production to order changes, <br>
              or advising customers of past due balances, dbTrigger&#153; is always 
              on the job; monitoring your <br>
              mission critical events so you can concentrate on making the right 
              decisions, at the right time.</td>
          </tr>
        </table>
        <table width="597" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td align="left" valign="middle" height="30"><img src="http://www.dbtrigger.com/newsletter/images/dots_corner.gif" width="597" height="12"></td>
          </tr>
        </table>
        <table width="597" border="0" cellspacing="0" cellpadding="0">
          <tr align="left" valign="top"> 
            <td width="24" align="left"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="24" height="1"></td>
            <td class="content"> 
              <p><img src="http://www.dbtrigger.com/newsletter/images/demo.gif" width="248" height="152" align="right"><img src="http://www.dbtrigger.com/newsletter/images/square.gif" width="12" height="20"><br>
                <img src="http://www.dbtrigger.com/newsletter/images/t_abreast.gif" width="199" height="15"> 
                <br>
                as they occur, anytime, anywhere. dbTrigger&#153; is always on 
                the job; monitoring your business so you don't have to:<br>
                <br>
                <img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Automatically 
                send payment reminders and <br>
                <img src="http://www.dbtrigger.com/newsletter/images/white_small.gif" width="13" height="7">overdue 
                notices to customers;<br>
                <img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Warn 
                suppliers of minimum or out of stock <br>
                <img src="http://www.dbtrigger.com/newsletter/images/white_small.gif" width="13" height="7">conditions;<br>
                <img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Inform 
                customers of order confirmations and <br>
                <img src="http://www.dbtrigger.com/newsletter/images/white_small.gif" width="13" height="7">product 
                shipments;<br>
                <img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Receive 
                instant notification of order changes and cancellations;<br><img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Advise 
                customers of expiring quotations, contracts, and price specials.<br>
                <img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Daily 
                cash, sales, invoice and other management reports received anywhere;<br>
                <img src="http://www.dbtrigger.com/newsletter/images/arrow_small.gif" width="13" height="7">Trigger 
                daily, weekly, and monthly sales and commission recaps to reps 
                and management;<br>
                <br>
               
                To see more examples, <a href="http://www.dbtrigger.com/main_sample.htm" class="links" target="_blank">Click 
                here</a>. <br>
                <br>
              </p>
              </td>
            <td width="26" valign="top" align="right"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="24" height="1"></td>
          </tr>
        </table>
        <table width="597" border="0" cellspacing="0" cellpadding="0">
          <tr> 
            <td align="left" valign="top"><img src="http://www.dbtrigger.com/newsletter/images/dots_corner.gif" width="597" height="12" vspace="5"></td>
          </tr>
        </table>
        <table width="597" border="0" cellspacing="0" cellpadding="0">
          <tr align="left" valign="top"> 
            <td width="18" valign="top" align="left">&nbsp;</td>
            <td width="269" valign="top" align="left" class="content"> 
              <p><img src="http://www.dbtrigger.com/newsletter/images/square.gif" width="12" height="20"><br>
                <img src="http://www.dbtrigger.com/newsletter/images/t_youwould.gif" width="157" height="11"> <br>
                Check out our <b>On-line</b> <b>Tour</b>. It will show you step-by-step 
                how easy it is to create triggers within your application. <img src="http://www.dbtrigger.com/newsletter/images/i_become.gif" width="86" height="78" align="left" vspace="15"><a href="http://www.dbtrigger.com/online_tour.htm" class="links" target="_blank"> 
                <br>
                <br>
                Click here</a> to see an <b>On-line</b> <b>Tour</b> of dbTrigger&#153;.</p>
              <p>Or, if you would like one of our dbTrigger&#153; partners to<font color="#FFFFFF">.</font>contact 
                you,&nbsp;<a href="http://www.dbtrigger.com/main_find_partner.htm" class="links" target="_blank">Click 
                here</a>.<br>
                <br>
              </p>
            </td>
            <td width="24" align="left" valign="bottom"><img src="http://www.dbtrigger.com/newsletter/images/dots_vertical.gif" width="18" height="151"><img src="../newsletter/images/vid.gif" width="24" height="1"></td>
            <td width="264" class="content"><img src="http://www.dbtrigger.com/newsletter/images/square.gif" width="12" height="20"><br>
              <img src="http://www.dbtrigger.com/newsletter/images/t_try.gif" width="160" height="13"> <br>
              Now you can test-drive the latest <img src="http://www.dbtrigger.com/newsletter/images/i_try.gif" width="91" height="95" align="left" vspace="12">version 
              of dbTrigger&#153;for 30 days without charge. The trial version 
              allows you to use most of the features found in the Business Edition, 
              so you can experience just how easy it is to use. <br>
              <a href="http://www.dbtrigger.com/main_tryit.htm" class="links" target="_blank"><br>
              Download dbTrigger&#153; Now!</a><br>
            </td>
            <td width="22" valign="top" align="right">&nbsp;</td>
          </tr>
          <tr align="left" valign="top"> 
            <td width="24" align="left">&nbsp;</td>
            <td width="264" class="content">&nbsp;</td>
            <td width="18" valign="top" align="left">&nbsp;</td>
            <td width="269" valign="top" align="left" class="content">&nbsp;</td>
            <td width="22" valign="top" align="right">&nbsp;</td>
          </tr>
        </table>
      </td>
      <td width="15" background="http://www.dbtrigger.com/newsletter/images/bg_right.gif"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="15" height="1"></td>
    </tr>
  </table>
  <table width="625" border="0" cellspacing="0" cellpadding="0">
    <tr align="left" valign="top"> 
      <td width="13" background="http://www.dbtrigger.com/newsletter/images/bg_left.gif" rowspan="3"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="13" height="1"></td>
      <td width="597" bgcolor="#000000" height="1"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="1" height="1"></td>
      <td width="15" background="http://www.dbtrigger.com/newsletter/images/bg_right.gif" rowspan="3"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="15" height="1"></td>
    </tr>
    <tr align="left" valign="top"> 
      <td width="597" bgcolor="#FFFFFF" height="30" class="content" valign="top" align="left"> 
        <table width="586" border="0" cellspacing="0" cellpadding="0">
          <tr align="left" valign="top"> 
            <td width="20" height="40">&nbsp;</td>
            <td class="content" width="556" height="40" valign="middle">We apologize 
              if you received this email in error. If you wish to <b>remove</b> 
              your name from dbTrigger&#153; news and events, please <a href="mailto:remove@dbtrigger.com?subject=Remove" class="links">Click 
              Here</a>. </td>
            <td width="10" height="40">&nbsp;</td>
          </tr>
          <tr>
            <td width="20">&nbsp;</td>
            <td class="content" width="556" align="left" valign="middle">&copy; 
              2001, dbTrigger&#153; LLC, Phone: 877-825-3009, Email: <a href="mailto:sales@dbtrigger.com?Subject=dbTrigger news">sales@dbTrigger.com</a><br>
            </td>
            <td width="10">&nbsp;</td>
          </tr>
        </table>
      </td>
    </tr>
    <tr align="left" valign="top"> 
      <td width="597" bgcolor="#000000" height="1"><img src="http://www.dbtrigger.com/newsletter/images/vid.gif" width="1" height="1"></td>
    </tr>
  </table>
</div>
<map name="Map"> 
  <area shape="rect" coords="3,2,148,51" href="http://www.dbtrigger.com" alt="www.dbtrigger.com" title="www.dbtrigger.com" target="_blank">
</map>
</body>
</html>





From Christoph.Schlenker@schlund.de Tue Feb 19 02:44:52 2002
Received: from mout03.kundenserver.de ([195.20.224.218])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16d4xI-00052k-00
	for <bug-commoncpp@gnu.org>; Tue, 19 Feb 2002 02:44:52 -0500
Received: from [195.20.224.148] (helo=mxintern.kundenserver.de)
	by mout03.kundenserver.de with esmtp (Exim 2.12 #2)
	id 16d4xG-0004n7-00
	for bug-commoncpp@gnu.org; Tue, 19 Feb 2002 08:44:50 +0100
Received: from [172.17.0.80] (helo=cschlenk.schlund.de)
	by mxintern.kundenserver.de with esmtp (Exim 2.12 #3)
	id 16d4xG-0001TS-00
	for bug-commoncpp@gnu.org; Tue, 19 Feb 2002 08:44:50 +0100
Subject: Release 2.0?
From: Christoph Schlenker <Christoph.Schlenker@schlund.de>
To: bug-commoncpp@gnu.org
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
X-Mailer: Evolution/1.0.2 
Date: 19 Feb 2002 08:49:35 +0100
Message-Id: <1014104975.25250.112.camel@cschlenk.schlund.de>
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/>

To wheover is listening:

The web page states that there will be a version 2.0 of the CommonC++.
Any release date or beta already?

Thanks,
\Christoph

-- 
Christoph Schlenker
Schlund + Partner AG
Erbprinzenstr. 4-12                      Tel.0721/91374-0
76133 Karlsruhe                          Fax.0721/91374-215
http://www.schlund.de                    Christoph.Schlenker@schlund.de



From dyfet@ostel.com Tue Feb 19 06:00:51 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16d80w-0006J7-00
	for <bug-commoncpp@gnu.org>; Tue, 19 Feb 2002 06:00:51 -0500
Received: by home.sys (Postfix, from userid 501)
	id 7DA631852F; Tue, 19 Feb 2002 06:17:12 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id 74B611852A; Tue, 19 Feb 2002 06:17:12 -0500 (EST)
Date: Tue, 19 Feb 2002 06:17:12 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: Christoph Schlenker <Christoph.Schlenker@schlund.de>
Cc: <bug-commoncpp@gnu.org>
Subject: Re: Release 2.0?
In-Reply-To: <1014104975.25250.112.camel@cschlenk.schlund.de>
Message-ID: <Pine.LNX.4.33L2.0202190615490.3388-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/>

Yes, the 0.99 release of GNU Common C++ 2 (commoncpp2, so that it can be
installed concurrently with the current releases) is likely to appear
by the end of next week.

On 19 Feb 2002, Christoph Schlenker wrote:

> To wheover is listening:
>
> The web page states that there will be a version 2.0 of the CommonC++.
> Any release date or beta already?
>
> Thanks,
> \Christoph
>
>



From ptsekov@syntrex.com Tue Feb 19 10:35:03 2002
Received: from host202-pool801891.interbusiness.it ([80.18.91.202] helo=syntrex.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dCII-000696-00
	for <bug-commoncpp@gnu.org>; Tue, 19 Feb 2002 10:35:02 -0500
Received: (qmail 21713 invoked by uid 8); 19 Feb 2002 16:35:58 -0000
Received: from 212-41-210-71.adsl.galactica.it (212.41.210.71, claiming to be "MORDOR")
	by mail.syntrex.com with SMTP id smtpdKE1i1b; Tue, 19 Feb 2002 11:35:51 EST
Date: Tue, 19 Feb 2002 16:34:46 +0100
From: Pavel Tsekov <ptsekov@syntrex.com>
X-Mailer: The Bat! (v1.53d) UNREG / CD5BF9353B3B7091
Reply-To: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex, Inc.
X-Priority: 3 (Normal)
Message-ID: <1824417109.20020219163446@syntrex.com>
To: bug-commoncpp@gnu.org
Subject: differences between getThread () on unices and win32
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
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/>

Hello, there! :)

getThread () on Win32 seem to not follow the trend and looks a
little bit outdated. It uses the old implementation - its the same
as in 1.6.x perhaps even before that. Would a patch be required to
add this functionality or not ? I would vote for simply copying the
unix implementation without the fix for Solaris... Is this acceptable
? If a a patch is required I'd supply one...

For the curious I've found this difference because of SEGV caused
by getException () which calls getThread () to retrieve the _throw
thread artifact on a thread other than the main one. Now I am curios
is it acceptable to remove the _throw member from thread and make it
a thread data ? This involves patching get/setException... Please, let
me know - I am willing to provide the patches - just want to know
if there are any pros / cons on this topic. I think a common situation
where this will be a better solution is applications which do not use
CommonC++ for their threading purposes.

Thanks :)



From tim@ba.be Tue Feb 19 11:21:45 2002
Received: from amsfep16-int.chello.nl ([213.46.243.25])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dD1V-0000Zi-00
	for <bug-commoncpp@gnu.org>; Tue, 19 Feb 2002 11:21:45 -0500
Received: from central.ba.be ([195.162.201.33]) by amsfep16-int.chello.nl
          (InterMail vM.5.01.03.06 201-253-122-118-106-20010523) with SMTP
          id <20020219161755.DGEF19167.amsfep16-int.chello.nl@central.ba.be>
          for <bug-commoncpp@gnu.org>; Tue, 19 Feb 2002 17:17:55 +0100
Received: (qmail 4716 invoked from network); 19 Feb 2002 16:21:43 -0000
Received: from oox.ba.be (10.0.0.57)
  by central.ba.be with SMTP; 19 Feb 2002 16:21:43 -0000
Content-Type: text/plain;
  charset="us-ascii"
From: Tim Esselens <tim@ba.be>
Organization: Better Access
To: bug-commoncpp@gnu.org
Subject: weird bug when using <iostream> includes
Date: Tue, 19 Feb 2002 17:21:43 +0100
X-Mailer: KMail [version 1.3.9]
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Message-Id: <200202191721.43221.tim@ba.be>
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 just started using your lib, and noticed the following problem:
if you #include <iostream> before the <thread.h> directive, something goes 
wrong:
/usr/include/cc++/thread.h:344: syntax error before `;'

Removal of the iostream include directive from my code fixed the problem. I 
assume this has something to do with PTHREAD defined rules within iostream. 
If you would like some more info, please let me know...

gcc: std rh-72: gcc-2.96, gcc3-3.0.1
cc++: 1.9.5

kind regards,
Tim Esselens



From david.durham@wcom.com Tue Feb 19 17:22:11 2002
Received: from pmesmtp01.wcom.com ([199.249.20.1])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16dIeJ-0008VR-00
	for <bug-commoncpp@gnu.org>; Tue, 19 Feb 2002 17:22:11 -0500
Received: from CONVERSION-DAEMON by firewall.wcom.com (PMDF V5.2-33 #47837)
 id <0GRS00801WRPXA@firewall.wcom.com> for bug-commoncpp@gnu.org; Tue,
 19 Feb 2002 22:21:25 +0000 (GMT)
Received: from dgismtp04.wcomnet.com ([166.38.58.144])
 by firewall.wcom.com (PMDF V5.2-33 #47837)
 with ESMTP id <0GRS0077QWRPIQ@firewall.wcom.com>; Tue,
 19 Feb 2002 22:21:25 +0000 (GMT)
Received: from dgismtp04.wcomnet.com by dgismtp04.wcomnet.com
 (PMDF V5.2-33 #42262) with SMTP id <0GRS00E01WR69F@dgismtp04.wcomnet.com>;
 Tue, 19 Feb 2002 22:21:24 +0000 (GMT)
Received: from wcom.com ([159.98.157.25])
 by dgismtp04.wcomnet.com (PMDF V5.2-33 #42262)
 with ESMTP id <0GRS00ABHWR29I@dgismtp04.wcomnet.com>; Tue,
 19 Feb 2002 22:21:03 +0000 (GMT)
Date: Tue, 19 Feb 2002 16:00:47 -0600
From: David Durham <david.durham@wcom.com>
Subject: Re: weird bug when using <iostream> includes
To: Tim Esselens <tim@ba.be>
Cc: bug-commoncpp@gnu.org
Message-id: <3C72CB0F.9090008@wcom.com>
MIME-version: 1.0
Content-type: text/plain; format=flowed; charset=us-ascii
Content-transfer-encoding: 7bit
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204
X-Accept-Language: en-us
References: <200202191721.43221.tim@ba.be>
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/>

try putting:  -D_GNU_SOURCE
on the compiler command


Tim Esselens wrote:

>Hi,
>
>I just started using your lib, and noticed the following problem:
>if you #include <iostream> before the <thread.h> directive, something goes 
>wrong:
>/usr/include/cc++/thread.h:344: syntax error before `;'
>
>Removal of the iostream include directive from my code fixed the problem. I 
>assume this has something to do with PTHREAD defined rules within iostream. 
>If you would like some more info, please let me know...
>
>gcc: std rh-72: gcc-2.96, gcc3-3.0.1
>cc++: 1.9.5
>
>kind regards,
>Tim Esselens
>
>
>_______________________________________________
>Bug-commoncpp mailing list
>Bug-commoncpp@gnu.org
>http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>





From Christoph.Schlenker@schlund.de Wed Feb 20 05:26:14 2002
Received: from mout04.kundenserver.de ([195.20.224.89])
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dTwz-0001U5-00
	for <bug-commoncpp@gnu.org>; Wed, 20 Feb 2002 05:26:14 -0500
Received: from [195.20.224.148] (helo=mxintern.kundenserver.de)
	by mout04.kundenserver.de with esmtp (Exim 2.12 #2)
	id 16dTwu-0007wF-00
	for bug-commoncpp@gnu.org; Wed, 20 Feb 2002 11:26:08 +0100
Received: from [172.17.0.80] (helo=cschlenk.schlund.de)
	by mxintern.kundenserver.de with esmtp (Exim 2.12 #3)
	id 16dTwt-0000J1-00
	for bug-commoncpp@gnu.org; Wed, 20 Feb 2002 11:26:07 +0100
Subject: Thread::isRunning() - bug?
From: Christoph Schlenker <Christoph.Schlenker@schlund.de>
To: bug-commoncpp@gnu.org
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
X-Mailer: Evolution/1.0.2 
Date: 20 Feb 2002 11:31:05 +0100
Message-Id: <1014201066.25251.228.camel@cschlenk.schlund.de>
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/>

Hi,

we have a hard to reproduce bug with the isRunning-Function in Thread.
Sometimes(!), when we create and delete "a lot of" (200) threads "very
fast" (asap), the isRunning()-function returns true, even if the
Final()-Function is called already.

(Our config.h makes the _tid not volatile, but that seems not the
problem.)

As a workaround we included our own isRunning2()-Function and a (non
volatile bool) in our derived Thread and it works fine. (isR2 = true in
Run(), isR2 = false in Final().

We're using gcc2.96, Linux-Kernel 2.4.7, CommonC++ 1.9.3.

Anyone else with that behaviour?

\Christoph





From dyfet@ostel.com Wed Feb 20 07:21:41 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dVki-0004Ov-00
	for <bug-commoncpp@gnu.org>; Wed, 20 Feb 2002 07:21:41 -0500
Received: from ostel.com (home [172.16.1.254])
	by home.sys (Postfix) with ESMTP
	id B501D37245; Wed, 20 Feb 2002 07:38:10 -0500 (EST)
Message-ID: <3C7398B2.2000705@ostel.com>
Date: Wed, 20 Feb 2002 07:38:10 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.4) Gecko/20010914
X-Accept-Language: en-us
MIME-Version: 1.0
To: Pavel Tsekov <ptsekov@syntrex.com>
Cc: bug-commoncpp@gnu.org,
	ZIGLIO Frediano <Frediano.Ziglio@omnitelvodafone.it>
Subject: Re: differences between getThread () on unices and win32
References: <1824417109.20020219163446@syntrex.com>
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/>

Freddy, do you think this issue is still in the 2 tree?  I recall this 
was changed around a bit...

Pavel Tsekov wrote:

>Hello, there! :)
>
>getThread () on Win32 seem to not follow the trend and looks a
>little bit outdated. It uses the old implementation - its the same
>as in 1.6.x perhaps even before that. Would a patch be required to
>add this functionality or not ? I would vote for simply copying the
>unix implementation without the fix for Solaris... Is this acceptable
>? If a a patch is required I'd supply one...
>
>For the curious I've found this difference because of SEGV caused
>by getException () which calls getThread () to retrieve the _throw
>thread artifact on a thread other than the main one. Now I am curios
>is it acceptable to remove the _throw member from thread and make it
>a thread data ? This involves patching get/setException... Please, let
>me know - I am willing to provide the patches - just want to know
>if there are any pros / cons on this topic. I think a common situation
>where this will be a better solution is applications which do not use
>CommonC++ for their threading purposes.
>
>Thanks :)
>
>
>_______________________________________________
>Bug-commoncpp mailing list
>Bug-commoncpp@gnu.org
>http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>




From ptsekov@syntrex.com Wed Feb 20 09:07:45 2002
Received: from host202-pool801891.interbusiness.it ([80.18.91.202] helo=syntrex.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dXPN-0006Q1-00
	for <bug-commoncpp@gnu.org>; Wed, 20 Feb 2002 09:07:45 -0500
Received: (qmail 29324 invoked by uid 8); 20 Feb 2002 15:08:39 -0000
Received: from 212-41-210-71.adsl.galactica.it (212.41.210.71, claiming to be "MORDOR")
	by mail.syntrex.com with SMTP id smtpdwcenF9; Wed, 20 Feb 2002 10:08:32 EST
Date: Wed, 20 Feb 2002 15:07:26 +0100
From: Pavel Tsekov <ptsekov@syntrex.com>
X-Mailer: The Bat! (v1.53d) UNREG / CD5BF9353B3B7091
Reply-To: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex, Inc.
X-Priority: 3 (Normal)
Message-ID: <7820365884.20020220150726@syntrex.com>
To: David Sugar <dyfet@ostel.com>
CC: bug-commoncpp@gnu.org
Subject: Re[2]: differences between getThread () on unices and win32
In-Reply-To: <3C7398B2.2000705@ostel.com>
References: <1824417109.20020219163446@syntrex.com> <3C7398B2.2000705@ostel.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
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/>

Hello David,

Just to let you know that the version I refer to is 1.9.5.

Btw is there an public accessible CVS server for CommonC++ ? Or
a web based one ?

Wednesday, February 20, 2002, 1:38:10 PM, you wrote:

DS> Freddy, do you think this issue is still in the 2 tree?  I recall this 
DS> was changed around a bit...

DS> Pavel Tsekov wrote:

>>Hello, there! :)
>>
>>getThread () on Win32 seem to not follow the trend and looks a
>>little bit outdated. It uses the old implementation - its the same
>>as in 1.6.x perhaps even before that. Would a patch be required to
>>add this functionality or not ? I would vote for simply copying the
>>unix implementation without the fix for Solaris... Is this acceptable
>>? If a a patch is required I'd supply one...
>>
>>For the curious I've found this difference because of SEGV caused
>>by getException () which calls getThread () to retrieve the _throw
>>thread artifact on a thread other than the main one. Now I am curios
>>is it acceptable to remove the _throw member from thread and make it
>>a thread data ? This involves patching get/setException... Please, let
>>me know - I am willing to provide the patches - just want to know
>>if there are any pros / cons on this topic. I think a common situation
>>where this will be a better solution is applications which do not use
>>CommonC++ for their threading purposes.
>>
>>Thanks :)



From dyfet@ostel.com Wed Feb 20 09:23:16 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dXeN-0007Ua-00
	for <bug-commoncpp@gnu.org>; Wed, 20 Feb 2002 09:23:15 -0500
Received: by home.sys (Postfix, from userid 501)
	id CAB5D1C7C7; Wed, 20 Feb 2002 09:39:45 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id C4A66185C1; Wed, 20 Feb 2002 09:39:45 -0500 (EST)
Date: Wed, 20 Feb 2002 09:39:45 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: Pavel Tsekov <ptsekov@syntrex.com>
Cc: <bug-commoncpp@gnu.org>
Subject: Re[2]: differences between getThread () on unices and win32
In-Reply-To: <7820365884.20020220150726@syntrex.com>
Message-ID: <Pine.LNX.4.33L2.0202200937030.21826-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/>

We are in the process of getting GNU Common C++ 2 ready for release and I
recall some work had been done on this issue.  This has not been
transferred into CVS in Savannah yet as it started as an entirely
experimental effort, but is in sourceforge public cvs, under
cvs.cplusplus.sourceforge.net:/cvsroot/CommonC++ I believe.

On Wed, 20 Feb 2002, Pavel Tsekov wrote:

> Hello David,
>
> Just to let you know that the version I refer to is 1.9.5.
>
> Btw is there an public accessible CVS server for CommonC++ ? Or
> a web based one ?
>
> Wednesday, February 20, 2002, 1:38:10 PM, you wrote:
>
> DS> Freddy, do you think this issue is still in the 2 tree?  I recall this
> DS> was changed around a bit...
>
> DS> Pavel Tsekov wrote:
>
> >>Hello, there! :)
> >>
> >>getThread () on Win32 seem to not follow the trend and looks a
> >>little bit outdated. It uses the old implementation - its the same
> >>as in 1.6.x perhaps even before that. Would a patch be required to
> >>add this functionality or not ? I would vote for simply copying the
> >>unix implementation without the fix for Solaris... Is this acceptable
> >>? If a a patch is required I'd supply one...
> >>
> >>For the curious I've found this difference because of SEGV caused
> >>by getException () which calls getThread () to retrieve the _throw
> >>thread artifact on a thread other than the main one. Now I am curios
> >>is it acceptable to remove the _throw member from thread and make it
> >>a thread data ? This involves patching get/setException... Please, let
> >>me know - I am willing to provide the patches - just want to know
> >>if there are any pros / cons on this topic. I think a common situation
> >>where this will be a better solution is applications which do not use
> >>CommonC++ for their threading purposes.
> >>
> >>Thanks :)
>
>



From ptsekov@syntrex.com Wed Feb 20 09:34:13 2002
Received: from host202-pool801891.interbusiness.it ([80.18.91.202] helo=syntrex.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16dXoy-0001iA-00
	for <bug-commoncpp@gnu.org>; Wed, 20 Feb 2002 09:34:13 -0500
Received: (qmail 30733 invoked by uid 8); 20 Feb 2002 15:35:11 -0000
Received: from 212-41-210-71.adsl.galactica.it (212.41.210.71, claiming to be "MORDOR")
	by mail.syntrex.com with SMTP id smtpdM9Pkm3; Wed, 20 Feb 2002 10:35:05 EST
Date: Wed, 20 Feb 2002 15:33:59 +0100
From: Pavel Tsekov <ptsekov@syntrex.com>
X-Mailer: The Bat! (v1.53d) UNREG / CD5BF9353B3B7091
Reply-To: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex, Inc.
X-Priority: 3 (Normal)
Message-ID: <2421959345.20020220153359@syntrex.com>
To: bug-commoncpp@gnu.org
Subject: Socket::isPending () issue
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
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/>

Hello :)

I want to raise another issue witch have made be go crazy for the
last few days :) On unices, based on your system a decision is made
if poll () or select () will be used to check if network data is
available for reading/writing. One would assume that using either of
these will give him the same result - but not. The version of Socket::isPending
() which uses poll () has an additional check - if the return value of
poll is -1 then a check is made if errno is set to EINTR and if
positive poll () is called again. This may result in an infinite loop.

I have a code which sends data through a tcpstream instance. Before
each write I do a Readline() with a timeout of 1000 milliseconds
to see if the other end wants to inform me of something. This seemed
to work fine though if I send a large amount of data (more than 5 Mb)
I got struck buy this issue - at some point the code blocks in the
isPending () and cannot get out of there. I solved the issue by using
the version of isPending () which uses select ().

Now my question is - what's the purpose for this difference in the
behaviour of isPending ().

Thanks ;)

P.S. The system is: i386 runnning RedHat Linux 7.2 - everything is stock, no
installation of custom packages.



From david.durham@wcom.com Thu Feb 21 12:23:36 2002
Received: from dgesmtp01.wcom.com ([199.249.16.16])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16dwwR-0001jH-00
	for <bug-commoncpp@gnu.org>; Thu, 21 Feb 2002 12:23:35 -0500
Received: from CONVERSION-DAEMON by firewall.wcom.com (PMDF V5.2-33 #42260)
 id <0GRW00C018B77Y@firewall.wcom.com> for bug-commoncpp@gnu.org; Thu,
 21 Feb 2002 17:23:31 +0000 (GMT)
Received: from pmismtp03.wcomnet.com ([166.38.62.38])
 by firewall.wcom.com (PMDF V5.2-33 #42260)
 with ESMTP id <0GRW00AEM8B6MW@firewall.wcom.com> for bug-commoncpp@gnu.org;
 Thu, 21 Feb 2002 17:23:31 +0000 (GMT)
Received: from pmismtp03.wcomnet.com by pmismtp03.wcomnet.com
 (PMDF V5.2-33 #42258) with SMTP id <0GRW008018B441@pmismtp03.wcomnet.com> for
 bug-commoncpp@gnu.org; Thu, 21 Feb 2002 17:23:30 +0000 (GMT)
Received: from wcom.com ([159.98.157.25])
 by pmismtp03.wcomnet.com (PMDF V5.2-33 #42258)
 with ESMTP id <0GRW005KR8AQG0@pmismtp03.wcomnet.com> for
 bug-commoncpp@gnu.org; Thu, 21 Feb 2002 17:23:15 +0000 (GMT)
Date: Thu, 21 Feb 2002 11:02:47 -0600
From: David Durham <david.durham@wcom.com>
Subject: new Path class
To: bug-commoncpp@gnu.org
Message-id: <3C752837.8070009@wcom.com>
MIME-version: 1.0
Content-type: multipart/mixed; boundary="Boundary_(ID_vjDfjS37B0xkDdzNvUsYjg)"
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204
X-Accept-Language: en-us
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.

--Boundary_(ID_vjDfjS37B0xkDdzNvUsYjg)
Content-type: text/plain; format=flowed; charset=us-ascii
Content-transfer-encoding: 7bit

   Hi,   I've created the Path class that I mentioned a few weeks 
back...   This is actually my first code to ever release as open 
source... I have lots of other code that I plan to release (like my 
application which uses this class), but am just not ready yet.  So I 
thought I'd start with this little thing.
I just copied the license notices from another source file in the 
library and changed the copyright year... I didn't change the name... 
you can have it ;)

   As far as the code goes: It has plenty of room for more 
functionality... I can imagine that there would be many other operations 
one might want to do on a path name than the operations I provided.  
   I didn't put any doxygen formatted comments, but I did put a few 
simple comments that explains a little what each method does.  
   Also, I was a little confused on how the rest of the CommonC++ 
library uses exceptions.  (I, myself, am well versed in exceptions 
though)  I saw that there was a define, "COMMON_STD_EXCEPTION" which is 
used.. If that define is not defined, it looks as if errors will go 
unreported at all... I also see throwing the object itself which seems a 
little strange... Anyway, what I did was just used exceptions throughout 
regardless of the define.. Change it if you want...
   One more thing about the exceptions...  I found that if I derived 
from CommonC++'s Exception class that when I threw an exception 
constructed from an std::string it wouldn't retain the whole message or 
something... So I commented out the code for PathException and just 
typedefed it to std::runtime_error which is very similar to ost::Exception
   Finally, I only wrote this for linux, I could (if you want) make sure 
it works under Solaris if that's one of the 'supported' platforms, but I 
just need to know what defines would indicate the platform (I suppose I 
could look in config.h)

So... change whatever you want... I hope it's useful.. it has been to me 
in my sound editor application where I often need to manipulate the 
dirname basename or extention, check for existance, etc... of path names.

-- Davy

--Boundary_(ID_vjDfjS37B0xkDdzNvUsYjg)
Content-type: text/plain; CHARSET=US-ASCII; name=path.h
Content-disposition: inline; filename=path.h
Content-transfer-encoding: 7bit

// Copyright (C) 2002 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.

#ifndef CCXX_path_H_
#define CCXX_path_H_

#include <string>

#ifndef CCXX_CONFIG_H_
	#include <cc++/config.h>
#endif

//see BBB note below  #include <cc++/exception.h>

#ifndef WIN32
	#include <sys/types.h>
	#include <sys/stat.h>
#else
	#error unimplemented for win32 platform
#endif


// see BBB note below (this is what I did instead)
#include <stdexcept>
typedef runtime_error PathException;



#ifdef  CCXX_NAMESPACES
namespace ost {
#endif

/* BBB: I tried using this, but it wouldn't retain the whole exception message at the throw... it did if I used runtime_error from stdexcept
   so, did what's above instead instead ...
class PathException : public Exception
{
public:
	PathException(std::string str) : Exception(str) {};
};
*/



class Path
{
public:
	static const char dirDelim; // either '\' or '/' depending on the platform

	Path(const std::string &path="");
	virtual ~Path();

	/*
		changes the path from what it was constructed with
	*/
	void setPath(const std::string &path);

	/*
		returns the path constructed with or the last one passed to setPath
	*/
	const char *getPath() const;

	/*
		returns true iff the pathname exists and we could access it
	*/
	bool Exists() const;

	/*
		possbily creates the path and/or updates its time(s) to current
	*/
	bool Touch(bool canCreate=true,bool throwIfError=true) const;

	/*
		returns the absolute path resolved from a possibly relative path
	*/
	const std::string RealPath() const;

	/*
		returns the extension of the path name (i.e. returns "ext" for "/dir1/dir2/file.ext")
	*/
	const std::string Extension() const;

	/*
		returns just the directory name(s) part of the path (i.e. returns "/dir1/dir2" for "/dir1/dir2/file.ext")
	*/
	const std::string DirName() const;
	
	/*
		returns just the filename part of the path (i.e. returns "file.ext" for "/dir1/dir2/file.ext")
	*/
	const std::string BaseName() const;

	/*
		returns the number of bytes allocated for the file
		either returns 0 or throws an exception if it doesn't exist or wasn't accessible
	*/
	long getSize(bool throwIfError=true) const;
	// many other things could be returned from the stat
	//time_t get ... Time() const;


private:
	char *path;
	bool exists;
	struct stat statBuf;

};

#ifdef  CCXX_NAMESPACES
}
#endif


#endif

--Boundary_(ID_vjDfjS37B0xkDdzNvUsYjg)
Content-type: text/plain; CHARSET=US-ASCII; name=path.cpp
Content-disposition: inline; filename=path.cpp
Content-transfer-encoding: 7bit

// Copyright (C) 2002 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 "path.h"

/*
	This was first written and tested under linux, however a few provisions
	have been made for a win32 port.  
	Also, several functions used are probably only available under linux, i.e.
		realpath, dirname, basename
	But there should be some equivalent under other unices, and implementation
	changes should be made when this file is compiled under these other platforms.
 */

#include <errno.h>

#ifndef WIN32
	#include <unistd.h>

	#include <fcntl.h>

	#include <limits.h>
	#include <stdlib.h>

	#include <string.h>

	#include <libgen.h>  // for basename and dirname
#else
	#error unimplemented for win32 platform
#endif


#ifdef  CCXX_NAMESPACES
namespace ost {
using namespace std;
#endif

#ifdef WIN32
	const char Path::dirDelim='\\';
#else
	const char Path::dirDelim='/';
#endif

Path::Path(const string &_path) :
	path(NULL),
	exists(false)
{
	setPath(_path);
}

Path::~Path()
{
	free(path);
}

void Path::setPath(const string &_path)
{
	if(_path.size()>=PATH_MAX)
		throw PathException(string(__func__)+" -- path is >= than PATH_MAX -- '"+path+"'");

	if(path!=NULL)
		free(path);
	path=strdup(_path.c_str());

	if(stat(path,&statBuf)!=0)
	{
		exists=false;
		if(errno!=ENOENT)
			throw PathException(string(__func__)+" -- error stat-ing path name -- '"+path+"' -- "+string(strerror(errno)));
	}
	else
		exists=true;
}

const char *Path::getPath() const
{
	return(path);
}

bool Path::Exists() const
{
	return(exists);
}

bool Path::Touch(bool canCreate,bool throwIfError) const
{
	if(canCreate)
	{
		int fd = open (path, O_WRONLY | O_CREAT | O_NONBLOCK | O_NOCTTY,S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
		if (fd == -1)
		{	
			if(throwIfError)
				throw PathException(string(__func__)+" -- error touching path name '"+path+"'-- "+string(strerror(errno)));
			else
				return(false);
		}
		close(fd);
	}
	else
	{
		int fd = open (path, O_WRONLY | O_NONBLOCK | O_NOCTTY,S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
		if (fd == -1 && errno!=ENOENT)
		{	
			if(throwIfError)
				throw PathException(string(__func__)+" -- error touching path name '"+path+"'-- "+string(strerror(errno)));
			else
				return(false);
		}

		if(fd!=-1)
			close(fd);
	}

	return(true);
}

const string Path::RealPath() const
{
	if(!exists)
		return("");

	char resolvedPath[PATH_MAX];
	char *result=realpath(path,resolvedPath);
	if(result!=NULL)
		return(result);
	else
		return("");
}

const string Path::Extension() const
{
	// find the right-most '.' which is also after the right-most dirDelim 

	char *lastDot=strrchr(path,'.');
	if(lastDot==NULL) // go ahead and bail if there wasn't even a '.' in the path
		return("");

	char *lastDirDelim=strrchr(path,dirDelim);

	if(lastDot>lastDirDelim)
		return(lastDot+1);
	else
		return("");
	
}

const string Path::DirName() const
{
	// make a copy because the function modifies the contents
	char tmp[PATH_MAX];
	strcpy(tmp,path);

	return(dirname(tmp));
}

const string Path::BaseName() const
{
	// make a copy because the function modifies the contents
	char tmp[PATH_MAX];
	strcpy(tmp,path);

	return(basename(tmp));
}


// many other things could possibly be returned from the stat
long Path::getSize(bool throwIfError) const
{
	if(!exists)
	{
		if(throwIfError)
			throw(PathException(string(__func__)+" -- path did not exist or was inaccessible -- '"+path+"'"));
		else
			return(0);
	}

	return(statBuf.st_size);
}

//time_t get ... Path::Time() const;

#ifdef  CCXX_NAMESPACES
}
#endif

--Boundary_(ID_vjDfjS37B0xkDdzNvUsYjg)
Content-type: text/plain; CHARSET=US-ASCII; name=testPath.cpp
Content-disposition: inline; filename=testPath.cpp
Content-transfer-encoding: 7bit

#include <iostream>
#include <stdexcept>

#include "path.h"

using ost::Path;

int main()
{
	cout << "testing class Path\n";

	try
	{
		Path p;

		p.setPath("/etc/../etc/resolv.conf");

		cout << "path: " << p.getPath() << endl;

	 	cout << "exists: " << p.Exists() << endl;
	 	cout << "touch: " << p.Touch(false,false) << endl;
	 	cout << "RealPath: " << p.RealPath() << endl;
	 	cout << "Extension: " << p.Extension() << endl;
		cout << "DirName: " << p.DirName() << endl;
		cout << "BaseName: " << p.BaseName() << endl;
		cout << "getSize: " << p.getSize() << endl;
	}
	catch(exception &e)
	{
		cerr << "UNEXPECTED exception -- " << e.what() << endl;
	}
	
	try
	{
		Path p;

		p.setPath("/etc/../etc/resolv.conf_pleasedontexist");

		cout << "path: " << p.getPath() << endl;

	 	cout << "exists: " << p.Exists() << endl;
	 	//cout << "touch: " << p.Touch(false,false) << endl;
	 	cout << "RealPath: " << p.RealPath() << endl;
	 	cout << "Extension: " << p.Extension() << endl;
		cout << "DirName: " << p.DirName() << endl;
		cout << "BaseName: " << p.BaseName() << endl;
		cout << "getSize: " << p.getSize(false) << endl;
	}
	catch(exception &e)
	{
		cerr << "UNEXPECTED exception -- " << e.what() << endl;
	}
	

	try
	{
		Path p;

		p.setPath("/etc/../etc/resolv.conf_pleasedontexist");

		cout << "path: " << p.getPath() << endl;

		cout << "getSize: " << p.getSize() << endl;
	}
	catch(exception &e)
	{
		cerr << "EXPECTED exception -- " << e.what() << endl;
	}
	

	return(0);
}

--Boundary_(ID_vjDfjS37B0xkDdzNvUsYjg)--


From dyfet@ostel.com Thu Feb 21 16:00:41 2002
Received: from [65.204.5.82] (helo=andromeda.sys)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16e0KX-0006N4-00
	for <bug-commoncpp@gnu.org>; Thu, 21 Feb 2002 16:00:41 -0500
Received: from ostel.com (localhost.localdomain [127.0.0.1])
	by andromeda.sys (8.11.4/8.11.4) with ESMTP id g1LL0ME22319;
	Thu, 21 Feb 2002 16:00:22 -0500
Message-ID: <3C755FE6.6020609@ostel.com>
Date: Thu, 21 Feb 2002 16:00:22 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.7) Gecko/20020107
X-Accept-Language: en-us
MIME-Version: 1.0
To: David Durham <david.durham@wcom.com>
CC: bug-commoncpp@gnu.org, Frediano Ziglio <freddyz77@tin.it>
Subject: Re: new Path class
References: <3C752837.8070009@wcom.com>
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/>

Right now we are in the process of validating Common C++ "2" for release 
very soon, so it may not be a good time to take this set of classes in 
at the moment.  I will look at these though....

David Durham wrote:

>   Hi,   I've created the Path class that I mentioned a few weeks 
> back...   This is actually my first code to ever release as open 
> source... I have lots of other code that I plan to release (like my 
> application which uses this class), but am just not ready yet.  So I 
> thought I'd start with this little thing.
> I just copied the license notices from another source file in the 
> library and changed the copyright year... I didn't change the name... 
> you can have it ;)
>
>   As far as the code goes: It has plenty of room for more 
> functionality... I can imagine that there would be many other 
> operations one might want to do on a path name than the operations I 
> provided.    I didn't put any doxygen formatted comments, but I did 
> put a few simple comments that explains a little what each method 
> does.    Also, I was a little confused on how the rest of the 
> CommonC++ library uses exceptions.  (I, myself, am well versed in 
> exceptions though)  I saw that there was a define, 
> "COMMON_STD_EXCEPTION" which is used.. If that define is not defined, 
> it looks as if errors will go unreported at all... I also see throwing 
> the object itself which seems a little strange... Anyway, what I did 
> was just used exceptions throughout regardless of the define.. Change 
> it if you want...
>   One more thing about the exceptions...  I found that if I derived 
> from CommonC++'s Exception class that when I threw an exception 
> constructed from an std::string it wouldn't retain the whole message 
> or something... So I commented out the code for PathException and just 
> typedefed it to std::runtime_error which is very similar to 
> ost::Exception
>   Finally, I only wrote this for linux, I could (if you want) make 
> sure it works under Solaris if that's one of the 'supported' 
> platforms, but I just need to know what defines would indicate the 
> platform (I suppose I could look in config.h)
>
> So... change whatever you want... I hope it's useful.. it has been to 
> me in my sound editor application where I often need to manipulate the 
> dirname basename or extention, check for existance, etc... of path names.
>
> -- Davy
>
>
>------------------------------------------------------------------------
>
>// Copyright (C) 2002 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.
>
>#ifndef CCXX_path_H_
>#define CCXX_path_H_
>
>#include <string>
>
>#ifndef CCXX_CONFIG_H_
>	#include <cc++/config.h>
>#endif
>
>//see BBB note below  #include <cc++/exception.h>
>
>#ifndef WIN32
>	#include <sys/types.h>
>	#include <sys/stat.h>
>#else
>	#error unimplemented for win32 platform
>#endif
>
>
>// see BBB note below (this is what I did instead)
>#include <stdexcept>
>typedef runtime_error PathException;
>
>
>
>#ifdef  CCXX_NAMESPACES
>namespace ost {
>#endif
>
>/* BBB: I tried using this, but it wouldn't retain the whole exception message at the throw... it did if I used runtime_error from stdexcept
>   so, did what's above instead instead ...
>class PathException : public Exception
>{
>public:
>	PathException(std::string str) : Exception(str) {};
>};
>*/
>
>
>
>class Path
>{
>public:
>	static const char dirDelim; // either '\' or '/' depending on the platform
>
>	Path(const std::string &path="");
>	virtual ~Path();
>
>	/*
>		changes the path from what it was constructed with
>	*/
>	void setPath(const std::string &path);
>
>	/*
>		returns the path constructed with or the last one passed to setPath
>	*/
>	const char *getPath() const;
>
>	/*
>		returns true iff the pathname exists and we could access it
>	*/
>	bool Exists() const;
>
>	/*
>		possbily creates the path and/or updates its time(s) to current
>	*/
>	bool Touch(bool canCreate=true,bool throwIfError=true) const;
>
>	/*
>		returns the absolute path resolved from a possibly relative path
>	*/
>	const std::string RealPath() const;
>
>	/*
>		returns the extension of the path name (i.e. returns "ext" for "/dir1/dir2/file.ext")
>	*/
>	const std::string Extension() const;
>
>	/*
>		returns just the directory name(s) part of the path (i.e. returns "/dir1/dir2" for "/dir1/dir2/file.ext")
>	*/
>	const std::string DirName() const;
>	
>	/*
>		returns just the filename part of the path (i.e. returns "file.ext" for "/dir1/dir2/file.ext")
>	*/
>	const std::string BaseName() const;
>
>	/*
>		returns the number of bytes allocated for the file
>		either returns 0 or throws an exception if it doesn't exist or wasn't accessible
>	*/
>	long getSize(bool throwIfError=true) const;
>	// many other things could be returned from the stat
>	//time_t get ... Time() const;
>
>
>private:
>	char *path;
>	bool exists;
>	struct stat statBuf;
>
>};
>
>#ifdef  CCXX_NAMESPACES
>}
>#endif
>
>
>#endif
>
>
>------------------------------------------------------------------------
>
>// Copyright (C) 2002 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 "path.h"
>
>/*
>	This was first written and tested under linux, however a few provisions
>	have been made for a win32 port.  
>	Also, several functions used are probably only available under linux, i.e.
>		realpath, dirname, basename
>	But there should be some equivalent under other unices, and implementation
>	changes should be made when this file is compiled under these other platforms.
> */
>
>#include <errno.h>
>
>#ifndef WIN32
>	#include <unistd.h>
>
>	#include <fcntl.h>
>
>	#include <limits.h>
>	#include <stdlib.h>
>
>	#include <string.h>
>
>	#include <libgen.h>  // for basename and dirname
>#else
>	#error unimplemented for win32 platform
>#endif
>
>
>#ifdef  CCXX_NAMESPACES
>namespace ost {
>using namespace std;
>#endif
>
>#ifdef WIN32
>	const char Path::dirDelim='\\';
>#else
>	const char Path::dirDelim='/';
>#endif
>
>Path::Path(const string &_path) :
>	path(NULL),
>	exists(false)
>{
>	setPath(_path);
>}
>
>Path::~Path()
>{
>	free(path);
>}
>
>void Path::setPath(const string &_path)
>{
>	if(_path.size()>=PATH_MAX)
>		throw PathException(string(__func__)+" -- path is >= than PATH_MAX -- '"+path+"'");
>
>	if(path!=NULL)
>		free(path);
>	path=strdup(_path.c_str());
>
>	if(stat(path,&statBuf)!=0)
>	{
>		exists=false;
>		if(errno!=ENOENT)
>			throw PathException(string(__func__)+" -- error stat-ing path name -- '"+path+"' -- "+string(strerror(errno)));
>	}
>	else
>		exists=true;
>}
>
>const char *Path::getPath() const
>{
>	return(path);
>}
>
>bool Path::Exists() const
>{
>	return(exists);
>}
>
>bool Path::Touch(bool canCreate,bool throwIfError) const
>{
>	if(canCreate)
>	{
>		int fd = open (path, O_WRONLY | O_CREAT | O_NONBLOCK | O_NOCTTY,S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
>		if (fd == -1)
>		{	
>			if(throwIfError)
>				throw PathException(string(__func__)+" -- error touching path name '"+path+"'-- "+string(strerror(errno)));
>			else
>				return(false);
>		}
>		close(fd);
>	}
>	else
>	{
>		int fd = open (path, O_WRONLY | O_NONBLOCK | O_NOCTTY,S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
>		if (fd == -1 && errno!=ENOENT)
>		{	
>			if(throwIfError)
>				throw PathException(string(__func__)+" -- error touching path name '"+path+"'-- "+string(strerror(errno)));
>			else
>				return(false);
>		}
>
>		if(fd!=-1)
>			close(fd);
>	}
>
>	return(true);
>}
>
>const string Path::RealPath() const
>{
>	if(!exists)
>		return("");
>
>	char resolvedPath[PATH_MAX];
>	char *result=realpath(path,resolvedPath);
>	if(result!=NULL)
>		return(result);
>	else
>		return("");
>}
>
>const string Path::Extension() const
>{
>	// find the right-most '.' which is also after the right-most dirDelim 
>
>	char *lastDot=strrchr(path,'.');
>	if(lastDot==NULL) // go ahead and bail if there wasn't even a '.' in the path
>		return("");
>
>	char *lastDirDelim=strrchr(path,dirDelim);
>
>	if(lastDot>lastDirDelim)
>		return(lastDot+1);
>	else
>		return("");
>	
>}
>
>const string Path::DirName() const
>{
>	// make a copy because the function modifies the contents
>	char tmp[PATH_MAX];
>	strcpy(tmp,path);
>
>	return(dirname(tmp));
>}
>
>const string Path::BaseName() const
>{
>	// make a copy because the function modifies the contents
>	char tmp[PATH_MAX];
>	strcpy(tmp,path);
>
>	return(basename(tmp));
>}
>
>
>// many other things could possibly be returned from the stat
>long Path::getSize(bool throwIfError) const
>{
>	if(!exists)
>	{
>		if(throwIfError)
>			throw(PathException(string(__func__)+" -- path did not exist or was inaccessible -- '"+path+"'"));
>		else
>			return(0);
>	}
>
>	return(statBuf.st_size);
>}
>
>//time_t get ... Path::Time() const;
>
>#ifdef  CCXX_NAMESPACES
>}
>#endif
>
>
>------------------------------------------------------------------------
>
>#include <iostream>
>#include <stdexcept>
>
>#include "path.h"
>
>using ost::Path;
>
>int main()
>{
>	cout << "testing class Path\n";
>
>	try
>	{
>		Path p;
>
>		p.setPath("/etc/../etc/resolv.conf");
>
>		cout << "path: " << p.getPath() << endl;
>
>	 	cout << "exists: " << p.Exists() << endl;
>	 	cout << "touch: " << p.Touch(false,false) << endl;
>	 	cout << "RealPath: " << p.RealPath() << endl;
>	 	cout << "Extension: " << p.Extension() << endl;
>		cout << "DirName: " << p.DirName() << endl;
>		cout << "BaseName: " << p.BaseName() << endl;
>		cout << "getSize: " << p.getSize() << endl;
>	}
>	catch(exception &e)
>	{
>		cerr << "UNEXPECTED exception -- " << e.what() << endl;
>	}
>	
>	try
>	{
>		Path p;
>
>		p.setPath("/etc/../etc/resolv.conf_pleasedontexist");
>
>		cout << "path: " << p.getPath() << endl;
>
>	 	cout << "exists: " << p.Exists() << endl;
>	 	//cout << "touch: " << p.Touch(false,false) << endl;
>	 	cout << "RealPath: " << p.RealPath() << endl;
>	 	cout << "Extension: " << p.Extension() << endl;
>		cout << "DirName: " << p.DirName() << endl;
>		cout << "BaseName: " << p.BaseName() << endl;
>		cout << "getSize: " << p.getSize(false) << endl;
>	}
>	catch(exception &e)
>	{
>		cerr << "UNEXPECTED exception -- " << e.what() << endl;
>	}
>	
>
>	try
>	{
>		Path p;
>
>		p.setPath("/etc/../etc/resolv.conf_pleasedontexist");
>
>		cout << "path: " << p.getPath() << endl;
>
>		cout << "getSize: " << p.getSize() << endl;
>	}
>	catch(exception &e)
>	{
>		cerr << "EXPECTED exception -- " << e.what() << endl;
>	}
>	
>
>	return(0);
>}
>





From david.durham@wcom.com Thu Feb 21 16:22:46 2002
Received: from pmesmtp02.wcom.com ([199.249.20.2])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16e0fu-0007Tc-00
	for <bug-commoncpp@gnu.org>; Thu, 21 Feb 2002 16:22:46 -0500
Received: from CONVERSION-DAEMON by firewall.wcom.com (PMDF V5.2-32 #42257)
 id <0GRW00B01JDW75@firewall.wcom.com> for bug-commoncpp@gnu.org; Thu,
 21 Feb 2002 21:22:44 +0000 (GMT)
Received: from pmismtp04.wcomnet.com ([166.38.62.39])
 by firewall.wcom.com (PMDF V5.2-32 #42257)
 with ESMTP id <0GRW008S6JDWM6@firewall.wcom.com>; Thu,
 21 Feb 2002 21:22:44 +0000 (GMT)
Received: from pmismtp04.wcomnet.com by pmismtp04.wcomnet.com
 (PMDF V5.2-33 #42258) with SMTP id <0GRW00501JDHWL@pmismtp04.wcomnet.com>;
 Thu, 21 Feb 2002 21:22:43 +0000 (GMT)
Received: from wcom.com ([159.98.157.25])
 by pmismtp04.wcomnet.com (PMDF V5.2-33 #42258)
 with ESMTP id <0GRW003GOJD55F@pmismtp04.wcomnet.com>; Thu,
 21 Feb 2002 21:22:17 +0000 (GMT)
Date: Thu, 21 Feb 2002 15:01:48 -0600
From: David Durham <david.durham@wcom.com>
Subject: Re: new Path class
To: David Sugar <dyfet@ostel.com>
Cc: bug-commoncpp@gnu.org, Frediano Ziglio <freddyz77@tin.it>
Message-id: <3C75603C.9060608@wcom.com>
MIME-version: 1.0
Content-type: text/plain; format=flowed; charset=us-ascii
Content-transfer-encoding: 7bit
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204
X-Accept-Language: en-us
References: <3C752837.8070009@wcom.com> <3C755FE6.6020609@ostel.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/>

I understand... Let me know of any changes I should make... Also, do you 
have a guess at when this might be able to go in? 1 month 3 months 1 yr?

Thanks,
   -- Davy

David Sugar wrote:

> Right now we are in the process of validating Common C++ "2" for 
> release very soon, so it may not be a good time to take this set of 
> classes in at the moment.  I will look at these though....
>
> David Durham wrote:
>
>>   Hi,   I've created the Path class that I mentioned a few weeks 
>> back...   This is actually my first code to ever release as open 
>> source... I have lots of other code that I plan to release (like my 
>> application which uses this class), but am just not ready yet.  So I 
>> thought I'd start with this little thing.
>> I just copied the license notices from another source file in the 
>> library and changed the copyright year... I didn't change the name... 
>> you can have it ;)
>>
>>   As far as the code goes: It has plenty of room for more 
>> functionality... I can imagine that there would be many other 
>> operations one might want to do on a path name than the operations I 
>> provided.    I didn't put any doxygen formatted comments, but I did 
>> put a few simple comments that explains a little what each method 
>> does.    Also, I was a little confused on how the rest of the 
>> CommonC++ library uses exceptions.  (I, myself, am well versed in 
>> exceptions though)  I saw that there was a define, 
>> "COMMON_STD_EXCEPTION" which is used.. If that define is not defined, 
>> it looks as if errors will go unreported at all... I also see 
>> throwing the object itself which seems a little strange... Anyway, 
>> what I did was just used exceptions throughout regardless of the 
>> define.. Change it if you want...
>>   One more thing about the exceptions...  I found that if I derived 
>> from CommonC++'s Exception class that when I threw an exception 
>> constructed from an std::string it wouldn't retain the whole message 
>> or something... So I commented out the code for PathException and 
>> just typedefed it to std::runtime_error which is very similar to 
>> ost::Exception
>>   Finally, I only wrote this for linux, I could (if you want) make 
>> sure it works under Solaris if that's one of the 'supported' 
>> platforms, but I just need to know what defines would indicate the 
>> platform (I suppose I could look in config.h)
>>
>> So... change whatever you want... I hope it's useful.. it has been to 
>> me in my sound editor application where I often need to manipulate 
>> the dirname basename or extention, check for existance, etc... of 
>> path names.
>>
>> -- Davy
>>
>>
>> ------------------------------------------------------------------------
>>
>> // Copyright (C) 2002 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.
>>
>> #ifndef CCXX_path_H_
>> #define CCXX_path_H_
>>
>> #include <string>
>>
>> #ifndef CCXX_CONFIG_H_
>>     #include <cc++/config.h>
>> #endif
>>
>> //see BBB note below  #include <cc++/exception.h>
>>
>> #ifndef WIN32
>>     #include <sys/types.h>
>>     #include <sys/stat.h>
>> #else
>>     #error unimplemented for win32 platform
>> #endif
>>
>>
>> // see BBB note below (this is what I did instead)
>> #include <stdexcept>
>> typedef runtime_error PathException;
>>
>>
>>
>> #ifdef  CCXX_NAMESPACES
>> namespace ost {
>> #endif
>>
>> /* BBB: I tried using this, but it wouldn't retain the whole 
>> exception message at the throw... it did if I used runtime_error from 
>> stdexcept
>>   so, did what's above instead instead ...
>> class PathException : public Exception
>> {
>> public:
>>     PathException(std::string str) : Exception(str) {};
>> };
>> */
>>
>>
>>
>> class Path
>> {
>> public:
>>     static const char dirDelim; // either '\' or '/' depending on the 
>> platform
>>
>>     Path(const std::string &path="");
>>     virtual ~Path();
>>
>>     /*
>>         changes the path from what it was constructed with
>>     */
>>     void setPath(const std::string &path);
>>
>>     /*
>>         returns the path constructed with or the last one passed to 
>> setPath
>>     */
>>     const char *getPath() const;
>>
>>     /*
>>         returns true iff the pathname exists and we could access it
>>     */
>>     bool Exists() const;
>>
>>     /*
>>         possbily creates the path and/or updates its time(s) to current
>>     */
>>     bool Touch(bool canCreate=true,bool throwIfError=true) const;
>>
>>     /*
>>         returns the absolute path resolved from a possibly relative path
>>     */
>>     const std::string RealPath() const;
>>
>>     /*
>>         returns the extension of the path name (i.e. returns "ext" 
>> for "/dir1/dir2/file.ext")
>>     */
>>     const std::string Extension() const;
>>
>>     /*
>>         returns just the directory name(s) part of the path (i.e. 
>> returns "/dir1/dir2" for "/dir1/dir2/file.ext")
>>     */
>>     const std::string DirName() const;
>>     
>>     /*
>>         returns just the filename part of the path (i.e. returns 
>> "file.ext" for "/dir1/dir2/file.ext")
>>     */
>>     const std::string BaseName() const;
>>
>>     /*
>>         returns the number of bytes allocated for the file
>>         either returns 0 or throws an exception if it doesn't exist 
>> or wasn't accessible
>>     */
>>     long getSize(bool throwIfError=true) const;
>>     // many other things could be returned from the stat
>>     //time_t get ... Time() const;
>>
>>
>> private:
>>     char *path;
>>     bool exists;
>>     struct stat statBuf;
>>
>> };
>>
>> #ifdef  CCXX_NAMESPACES
>> }
>> #endif
>>
>>
>> #endif
>>
>>
>> ------------------------------------------------------------------------
>>
>> // Copyright (C) 2002 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 "path.h"
>>
>> /*
>>     This was first written and tested under linux, however a few 
>> provisions
>>     have been made for a win32 port.      Also, several functions 
>> used are probably only available under linux, i.e.
>>         realpath, dirname, basename
>>     But there should be some equivalent under other unices, and 
>> implementation
>>     changes should be made when this file is compiled under these 
>> other platforms.
>> */
>>
>> #include <errno.h>
>>
>> #ifndef WIN32
>>     #include <unistd.h>
>>
>>     #include <fcntl.h>
>>
>>     #include <limits.h>
>>     #include <stdlib.h>
>>
>>     #include <string.h>
>>
>>     #include <libgen.h>  // for basename and dirname
>> #else
>>     #error unimplemented for win32 platform
>> #endif
>>
>>
>> #ifdef  CCXX_NAMESPACES
>> namespace ost {
>> using namespace std;
>> #endif
>>
>> #ifdef WIN32
>>     const char Path::dirDelim='\\';
>> #else
>>     const char Path::dirDelim='/';
>> #endif
>>
>> Path::Path(const string &_path) :
>>     path(NULL),
>>     exists(false)
>> {
>>     setPath(_path);
>> }
>>
>> Path::~Path()
>> {
>>     free(path);
>> }
>>
>> void Path::setPath(const string &_path)
>> {
>>     if(_path.size()>=PATH_MAX)
>>         throw PathException(string(__func__)+" -- path is >= than 
>> PATH_MAX -- '"+path+"'");
>>
>>     if(path!=NULL)
>>         free(path);
>>     path=strdup(_path.c_str());
>>
>>     if(stat(path,&statBuf)!=0)
>>     {
>>         exists=false;
>>         if(errno!=ENOENT)
>>             throw PathException(string(__func__)+" -- error stat-ing 
>> path name -- '"+path+"' -- "+string(strerror(errno)));
>>     }
>>     else
>>         exists=true;
>> }
>>
>> const char *Path::getPath() const
>> {
>>     return(path);
>> }
>>
>> bool Path::Exists() const
>> {
>>     return(exists);
>> }
>>
>> bool Path::Touch(bool canCreate,bool throwIfError) const
>> {
>>     if(canCreate)
>>     {
>>         int fd = open (path, O_WRONLY | O_CREAT | O_NONBLOCK | 
>> O_NOCTTY,S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
>>         if (fd == -1)
>>         {   
>>             if(throwIfError)
>>                 throw PathException(string(__func__)+" -- error 
>> touching path name '"+path+"'-- "+string(strerror(errno)));
>>             else
>>                 return(false);
>>         }
>>         close(fd);
>>     }
>>     else
>>     {
>>         int fd = open (path, O_WRONLY | O_NONBLOCK | O_NOCTTY,S_IRUSR 
>> | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
>>         if (fd == -1 && errno!=ENOENT)
>>         {   
>>             if(throwIfError)
>>                 throw PathException(string(__func__)+" -- error 
>> touching path name '"+path+"'-- "+string(strerror(errno)));
>>             else
>>                 return(false);
>>         }
>>
>>         if(fd!=-1)
>>             close(fd);
>>     }
>>
>>     return(true);
>> }
>>
>> const string Path::RealPath() const
>> {
>>     if(!exists)
>>         return("");
>>
>>     char resolvedPath[PATH_MAX];
>>     char *result=realpath(path,resolvedPath);
>>     if(result!=NULL)
>>         return(result);
>>     else
>>         return("");
>> }
>>
>> const string Path::Extension() const
>> {
>>     // find the right-most '.' which is also after the right-most 
>> dirDelim
>>     char *lastDot=strrchr(path,'.');
>>     if(lastDot==NULL) // go ahead and bail if there wasn't even a '.' 
>> in the path
>>         return("");
>>
>>     char *lastDirDelim=strrchr(path,dirDelim);
>>
>>     if(lastDot>lastDirDelim)
>>         return(lastDot+1);
>>     else
>>         return("");
>>     
>> }
>>
>> const string Path::DirName() const
>> {
>>     // make a copy because the function modifies the contents
>>     char tmp[PATH_MAX];
>>     strcpy(tmp,path);
>>
>>     return(dirname(tmp));
>> }
>>
>> const string Path::BaseName() const
>> {
>>     // make a copy because the function modifies the contents
>>     char tmp[PATH_MAX];
>>     strcpy(tmp,path);
>>
>>     return(basename(tmp));
>> }
>>
>>
>> // many other things could possibly be returned from the stat
>> long Path::getSize(bool throwIfError) const
>> {
>>     if(!exists)
>>     {
>>         if(throwIfError)
>>             throw(PathException(string(__func__)+" -- path did not 
>> exist or was inaccessible -- '"+path+"'"));
>>         else
>>             return(0);
>>     }
>>
>>     return(statBuf.st_size);
>> }
>>
>> //time_t get ... Path::Time() const;
>>
>> #ifdef  CCXX_NAMESPACES
>> }
>> #endif
>>
>>
>> ------------------------------------------------------------------------
>>
>> #include <iostream>
>> #include <stdexcept>
>>
>> #include "path.h"
>>
>> using ost::Path;
>>
>> int main()
>> {
>>     cout << "testing class Path\n";
>>
>>     try
>>     {
>>         Path p;
>>
>>         p.setPath("/etc/../etc/resolv.conf");
>>
>>         cout << "path: " << p.getPath() << endl;
>>
>>          cout << "exists: " << p.Exists() << endl;
>>          cout << "touch: " << p.Touch(false,false) << endl;
>>          cout << "RealPath: " << p.RealPath() << endl;
>>          cout << "Extension: " << p.Extension() << endl;
>>         cout << "DirName: " << p.DirName() << endl;
>>         cout << "BaseName: " << p.BaseName() << endl;
>>         cout << "getSize: " << p.getSize() << endl;
>>     }
>>     catch(exception &e)
>>     {
>>         cerr << "UNEXPECTED exception -- " << e.what() << endl;
>>     }
>>     
>>     try
>>     {
>>         Path p;
>>
>>         p.setPath("/etc/../etc/resolv.conf_pleasedontexist");
>>
>>         cout << "path: " << p.getPath() << endl;
>>
>>          cout << "exists: " << p.Exists() << endl;
>>          //cout << "touch: " << p.Touch(false,false) << endl;
>>          cout << "RealPath: " << p.RealPath() << endl;
>>          cout << "Extension: " << p.Extension() << endl;
>>         cout << "DirName: " << p.DirName() << endl;
>>         cout << "BaseName: " << p.BaseName() << endl;
>>         cout << "getSize: " << p.getSize(false) << endl;
>>     }
>>     catch(exception &e)
>>     {
>>         cerr << "UNEXPECTED exception -- " << e.what() << endl;
>>     }
>>     
>>
>>     try
>>     {
>>         Path p;
>>
>>         p.setPath("/etc/../etc/resolv.conf_pleasedontexist");
>>
>>         cout << "path: " << p.getPath() << endl;
>>
>>         cout << "getSize: " << p.getSize() << endl;
>>     }
>>     catch(exception &e)
>>     {
>>         cerr << "EXPECTED exception -- " << e.what() << endl;
>>     }
>>     
>>
>>     return(0);
>> }
>>
>
>
>
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>





From dyfet@ostel.com Thu Feb 21 16:47:53 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16e149-0002FD-00
	for <bug-commoncpp@gnu.org>; Thu, 21 Feb 2002 16:47:50 -0500
Received: by home.sys (Postfix, from userid 501)
	id 2581A34FE5; Thu, 21 Feb 2002 17:04:29 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id 1AECE34FE0; Thu, 21 Feb 2002 17:04:29 -0500 (EST)
Date: Thu, 21 Feb 2002 17:04:29 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: David Durham <david.durham@wcom.com>
Cc: <bug-commoncpp@gnu.org>, Frediano Ziglio <freddyz77@tin.it>
Subject: Re: new Path class
In-Reply-To: <3C75603C.9060608@wcom.com>
Message-ID: <Pine.LNX.4.33L2.0202211703370.30863-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 guessing 1 month.  Freddy is looking it over to see if we could do it
in the "2" initial release...

On Thu, 21 Feb 2002, David Durham wrote:

> I understand... Let me know of any changes I should make... Also, do you
> have a guess at when this might be able to go in? 1 month 3 months 1 yr?
>
> Thanks,
>    -- Davy
>
> David Sugar wrote:
>
> > Right now we are in the process of validating Common C++ "2" for
> > release very soon, so it may not be a good time to take this set of
> > classes in at the moment.  I will look at these though....
> >
> > David Durham wrote:
> >
> >>   Hi,   I've created the Path class that I mentioned a few weeks
> >> back...   This is actually my first code to ever release as open
> >> source... I have lots of other code that I plan to release (like my
> >> application which uses this class), but am just not ready yet.  So I
> >> thought I'd start with this little thing.
> >> I just copied the license notices from another source file in the
> >> library and changed the copyright year... I didn't change the name...
> >> you can have it ;)
> >>
> >>   As far as the code goes: It has plenty of room for more
> >> functionality... I can imagine that there would be many other
> >> operations one might want to do on a path name than the operations I
> >> provided.    I didn't put any doxygen formatted comments, but I did
> >> put a few simple comments that explains a little what each method
> >> does.    Also, I was a little confused on how the rest of the
> >> CommonC++ library uses exceptions.  (I, myself, am well versed in
> >> exceptions though)  I saw that there was a define,
> >> "COMMON_STD_EXCEPTION" which is used.. If that define is not defined,
> >> it looks as if errors will go unreported at all... I also see
> >> throwing the object itself which seems a little strange... Anyway,
> >> what I did was just used exceptions throughout regardless of the
> >> define.. Change it if you want...
> >>   One more thing about the exceptions...  I found that if I derived
> >> from CommonC++'s Exception class that when I threw an exception
> >> constructed from an std::string it wouldn't retain the whole message
> >> or something... So I commented out the code for PathException and
> >> just typedefed it to std::runtime_error which is very similar to
> >> ost::Exception
> >>   Finally, I only wrote this for linux, I could (if you want) make
> >> sure it works under Solaris if that's one of the 'supported'
> >> platforms, but I just need to know what defines would indicate the
> >> platform (I suppose I could look in config.h)
> >>
> >> So... change whatever you want... I hope it's useful.. it has been to
> >> me in my sound editor application where I often need to manipulate
> >> the dirname basename or extention, check for existance, etc... of
> >> path names.
> >>
> >> -- Davy
> >>
> >>
> >> ------------------------------------------------------------------------
> >>
> >> // Copyright (C) 2002 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.
> >>
> >> #ifndef CCXX_path_H_
> >> #define CCXX_path_H_
> >>
> >> #include <string>
> >>
> >> #ifndef CCXX_CONFIG_H_
> >>     #include <cc++/config.h>
> >> #endif
> >>
> >> //see BBB note below  #include <cc++/exception.h>
> >>
> >> #ifndef WIN32
> >>     #include <sys/types.h>
> >>     #include <sys/stat.h>
> >> #else
> >>     #error unimplemented for win32 platform
> >> #endif
> >>
> >>
> >> // see BBB note below (this is what I did instead)
> >> #include <stdexcept>
> >> typedef runtime_error PathException;
> >>
> >>
> >>
> >> #ifdef  CCXX_NAMESPACES
> >> namespace ost {
> >> #endif
> >>
> >> /* BBB: I tried using this, but it wouldn't retain the whole
> >> exception message at the throw... it did if I used runtime_error from
> >> stdexcept
> >>   so, did what's above instead instead ...
> >> class PathException : public Exception
> >> {
> >> public:
> >>     PathException(std::string str) : Exception(str) {};
> >> };
> >> */
> >>
> >>
> >>
> >> class Path
> >> {
> >> public:
> >>     static const char dirDelim; // either '\' or '/' depending on the
> >> platform
> >>
> >>     Path(const std::string &path="");
> >>     virtual ~Path();
> >>
> >>     /*
> >>         changes the path from what it was constructed with
> >>     */
> >>     void setPath(const std::string &path);
> >>
> >>     /*
> >>         returns the path constructed with or the last one passed to
> >> setPath
> >>     */
> >>     const char *getPath() const;
> >>
> >>     /*
> >>         returns true iff the pathname exists and we could access it
> >>     */
> >>     bool Exists() const;
> >>
> >>     /*
> >>         possbily creates the path and/or updates its time(s) to current
> >>     */
> >>     bool Touch(bool canCreate=true,bool throwIfError=true) const;
> >>
> >>     /*
> >>         returns the absolute path resolved from a possibly relative path
> >>     */
> >>     const std::string RealPath() const;
> >>
> >>     /*
> >>         returns the extension of the path name (i.e. returns "ext"
> >> for "/dir1/dir2/file.ext")
> >>     */
> >>     const std::string Extension() const;
> >>
> >>     /*
> >>         returns just the directory name(s) part of the path (i.e.
> >> returns "/dir1/dir2" for "/dir1/dir2/file.ext")
> >>     */
> >>     const std::string DirName() const;
> >>
> >>     /*
> >>         returns just the filename part of the path (i.e. returns
> >> "file.ext" for "/dir1/dir2/file.ext")
> >>     */
> >>     const std::string BaseName() const;
> >>
> >>     /*
> >>         returns the number of bytes allocated for the file
> >>         either returns 0 or throws an exception if it doesn't exist
> >> or wasn't accessible
> >>     */
> >>     long getSize(bool throwIfError=true) const;
> >>     // many other things could be returned from the stat
> >>     //time_t get ... Time() const;
> >>
> >>
> >> private:
> >>     char *path;
> >>     bool exists;
> >>     struct stat statBuf;
> >>
> >> };
> >>
> >> #ifdef  CCXX_NAMESPACES
> >> }
> >> #endif
> >>
> >>
> >> #endif
> >>
> >>
> >> ------------------------------------------------------------------------
> >>
> >> // Copyright (C) 2002 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 "path.h"
> >>
> >> /*
> >>     This was first written and tested under linux, however a few
> >> provisions
> >>     have been made for a win32 port.      Also, several functions
> >> used are probably only available under linux, i.e.
> >>         realpath, dirname, basename
> >>     But there should be some equivalent under other unices, and
> >> implementation
> >>     changes should be made when this file is compiled under these
> >> other platforms.
> >> */
> >>
> >> #include <errno.h>
> >>
> >> #ifndef WIN32
> >>     #include <unistd.h>
> >>
> >>     #include <fcntl.h>
> >>
> >>     #include <limits.h>
> >>     #include <stdlib.h>
> >>
> >>     #include <string.h>
> >>
> >>     #include <libgen.h>  // for basename and dirname
> >> #else
> >>     #error unimplemented for win32 platform
> >> #endif
> >>
> >>
> >> #ifdef  CCXX_NAMESPACES
> >> namespace ost {
> >> using namespace std;
> >> #endif
> >>
> >> #ifdef WIN32
> >>     const char Path::dirDelim='\\';
> >> #else
> >>     const char Path::dirDelim='/';
> >> #endif
> >>
> >> Path::Path(const string &_path) :
> >>     path(NULL),
> >>     exists(false)
> >> {
> >>     setPath(_path);
> >> }
> >>
> >> Path::~Path()
> >> {
> >>     free(path);
> >> }
> >>
> >> void Path::setPath(const string &_path)
> >> {
> >>     if(_path.size()>=PATH_MAX)
> >>         throw PathException(string(__func__)+" -- path is >= than
> >> PATH_MAX -- '"+path+"'");
> >>
> >>     if(path!=NULL)
> >>         free(path);
> >>     path=strdup(_path.c_str());
> >>
> >>     if(stat(path,&statBuf)!=0)
> >>     {
> >>         exists=false;
> >>         if(errno!=ENOENT)
> >>             throw PathException(string(__func__)+" -- error stat-ing
> >> path name -- '"+path+"' -- "+string(strerror(errno)));
> >>     }
> >>     else
> >>         exists=true;
> >> }
> >>
> >> const char *Path::getPath() const
> >> {
> >>     return(path);
> >> }
> >>
> >> bool Path::Exists() const
> >> {
> >>     return(exists);
> >> }
> >>
> >> bool Path::Touch(bool canCreate,bool throwIfError) const
> >> {
> >>     if(canCreate)
> >>     {
> >>         int fd = open (path, O_WRONLY | O_CREAT | O_NONBLOCK |
> >> O_NOCTTY,S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
> >>         if (fd == -1)
> >>         {
> >>             if(throwIfError)
> >>                 throw PathException(string(__func__)+" -- error
> >> touching path name '"+path+"'-- "+string(strerror(errno)));
> >>             else
> >>                 return(false);
> >>         }
> >>         close(fd);
> >>     }
> >>     else
> >>     {
> >>         int fd = open (path, O_WRONLY | O_NONBLOCK | O_NOCTTY,S_IRUSR
> >> | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
> >>         if (fd == -1 && errno!=ENOENT)
> >>         {
> >>             if(throwIfError)
> >>                 throw PathException(string(__func__)+" -- error
> >> touching path name '"+path+"'-- "+string(strerror(errno)));
> >>             else
> >>                 return(false);
> >>         }
> >>
> >>         if(fd!=-1)
> >>             close(fd);
> >>     }
> >>
> >>     return(true);
> >> }
> >>
> >> const string Path::RealPath() const
> >> {
> >>     if(!exists)
> >>         return("");
> >>
> >>     char resolvedPath[PATH_MAX];
> >>     char *result=realpath(path,resolvedPath);
> >>     if(result!=NULL)
> >>         return(result);
> >>     else
> >>         return("");
> >> }
> >>
> >> const string Path::Extension() const
> >> {
> >>     // find the right-most '.' which is also after the right-most
> >> dirDelim
> >>     char *lastDot=strrchr(path,'.');
> >>     if(lastDot==NULL) // go ahead and bail if there wasn't even a '.'
> >> in the path
> >>         return("");
> >>
> >>     char *lastDirDelim=strrchr(path,dirDelim);
> >>
> >>     if(lastDot>lastDirDelim)
> >>         return(lastDot+1);
> >>     else
> >>         return("");
> >>
> >> }
> >>
> >> const string Path::DirName() const
> >> {
> >>     // make a copy because the function modifies the contents
> >>     char tmp[PATH_MAX];
> >>     strcpy(tmp,path);
> >>
> >>     return(dirname(tmp));
> >> }
> >>
> >> const string Path::BaseName() const
> >> {
> >>     // make a copy because the function modifies the contents
> >>     char tmp[PATH_MAX];
> >>     strcpy(tmp,path);
> >>
> >>     return(basename(tmp));
> >> }
> >>
> >>
> >> // many other things could possibly be returned from the stat
> >> long Path::getSize(bool throwIfError) const
> >> {
> >>     if(!exists)
> >>     {
> >>         if(throwIfError)
> >>             throw(PathException(string(__func__)+" -- path did not
> >> exist or was inaccessible -- '"+path+"'"));
> >>         else
> >>             return(0);
> >>     }
> >>
> >>     return(statBuf.st_size);
> >> }
> >>
> >> //time_t get ... Path::Time() const;
> >>
> >> #ifdef  CCXX_NAMESPACES
> >> }
> >> #endif
> >>
> >>
> >> ------------------------------------------------------------------------
> >>
> >> #include <iostream>
> >> #include <stdexcept>
> >>
> >> #include "path.h"
> >>
> >> using ost::Path;
> >>
> >> int main()
> >> {
> >>     cout << "testing class Path\n";
> >>
> >>     try
> >>     {
> >>         Path p;
> >>
> >>         p.setPath("/etc/../etc/resolv.conf");
> >>
> >>         cout << "path: " << p.getPath() << endl;
> >>
> >>          cout << "exists: " << p.Exists() << endl;
> >>          cout << "touch: " << p.Touch(false,false) << endl;
> >>          cout << "RealPath: " << p.RealPath() << endl;
> >>          cout << "Extension: " << p.Extension() << endl;
> >>         cout << "DirName: " << p.DirName() << endl;
> >>         cout << "BaseName: " << p.BaseName() << endl;
> >>         cout << "getSize: " << p.getSize() << endl;
> >>     }
> >>     catch(exception &e)
> >>     {
> >>         cerr << "UNEXPECTED exception -- " << e.what() << endl;
> >>     }
> >>
> >>     try
> >>     {
> >>         Path p;
> >>
> >>         p.setPath("/etc/../etc/resolv.conf_pleasedontexist");
> >>
> >>         cout << "path: " << p.getPath() << endl;
> >>
> >>          cout << "exists: " << p.Exists() << endl;
> >>          //cout << "touch: " << p.Touch(false,false) << endl;
> >>          cout << "RealPath: " << p.RealPath() << endl;
> >>          cout << "Extension: " << p.Extension() << endl;
> >>         cout << "DirName: " << p.DirName() << endl;
> >>         cout << "BaseName: " << p.BaseName() << endl;
> >>         cout << "getSize: " << p.getSize(false) << endl;
> >>     }
> >>     catch(exception &e)
> >>     {
> >>         cerr << "UNEXPECTED exception -- " << e.what() << endl;
> >>     }
> >>
> >>
> >>     try
> >>     {
> >>         Path p;
> >>
> >>         p.setPath("/etc/../etc/resolv.conf_pleasedontexist");
> >>
> >>         cout << "path: " << p.getPath() << endl;
> >>
> >>         cout << "getSize: " << p.getSize() << endl;
> >>     }
> >>     catch(exception &e)
> >>     {
> >>         cerr << "EXPECTED exception -- " << e.what() << endl;
> >>     }
> >>
> >>
> >>     return(0);
> >> }
> >>
> >
> >
> >
> >
> > _______________________________________________
> > Bug-commoncpp mailing list
> > Bug-commoncpp@gnu.org
> > http://mail.gnu.org/mailman/listinfo/bug-commoncpp
> >
>
>
>
>



From flavio.oliveira@inttegra.com.br Thu Feb 21 17:58:07 2002
Received: from toole.uol.com.br ([200.231.206.186])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16e2AA-0000WT-00
	for <bug-commoncpp@gnu.org>; Thu, 21 Feb 2002 17:58:06 -0500
Received: from DFCP0030 ([200.193.226.141])
	by toole.uol.com.br (8.9.1/8.9.1) with SMTP id TAA16936
	for <bug-commoncpp@gnu.org>; Thu, 21 Feb 2002 19:54:25 -0300 (BRT)
From: "Flavio Oliveira" <flavio.oliveira@inttegra.com.br>
To: <bug-commoncpp@gnu.org>
Subject: CommonC++-1.9.5
Date: Thu, 21 Feb 2002 19:59:17 -0300
Message-ID: <JLENJOAMOMNJCILEOGMJCEBHCBAA.flavio.oliveira@inttegra.com.br>
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
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.2919.6700
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 am using a Solaris 8.0, and i have the message when execute
./configure:

# ./configure
loading cache ./config.cache
checking host system type... sparc-sun-solaris2.8
checking target system type... sparc-sun-solaris2.8
checking build system type... sparc-sun-solaris2.8
checking for MSC environment... ./configure: cl: not found
no
checking for a BSD compatible install... config/install-sh -c
checking whether build environment is sane... configure:
error: newly created file is older than distributed files!
Check your system clock

I don't know how to compile with make, i type : /usr/ccs/bin/make
to compile the package, but which are the parameters?

Thank you, flavio.



From ptsekov@syntrex.com Fri Feb 22 04:12:12 2002
Received: from host202-pool801891.interbusiness.it ([80.18.91.202] helo=syntrex.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16eBkR-00069v-00
	for <bug-commoncpp@gnu.org>; Fri, 22 Feb 2002 04:12:11 -0500
Received: (qmail 29695 invoked by uid 8); 22 Feb 2002 10:13:06 -0000
Received: from 212-41-210-71.adsl.galactica.it (212.41.210.71, claiming to be "MORDOR")
	by mail.syntrex.com with SMTP id smtpdZYbLd4; Fri, 22 Feb 2002 05:12:59 EST
Date: Fri, 22 Feb 2002 10:11:49 +0100
From: Pavel Tsekov <ptsekov@syntrex.com>
X-Mailer: The Bat! (v1.53d) UNREG / CD5BF9353B3B7091
Reply-To: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex, Inc.
X-Priority: 3 (Normal)
Message-ID: <371453229.20020222101149@syntrex.com>
To: Pavel Tsekov <ptsekov@syntrex.com>
CC: bug-commoncpp@gnu.org
Subject: Re: Socket::isPending () issue
In-Reply-To: <2421959345.20020220153359@syntrex.com>
References: <2421959345.20020220153359@syntrex.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
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/>

Hey there :)

Does anyone read this message ? Any ideas ?

Wednesday, February 20, 2002, 3:33:59 PM, I wrote:

[ snip ]

PT> Now my question is - what's the purpose for this difference in the
PT> behaviour of isPending ().

Thanks :)



From ptsekov@syntrex.com Fri Feb 22 04:14:06 2002
Received: from host202-pool801891.interbusiness.it ([80.18.91.202] helo=syntrex.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16eBmH-0006MO-00
	for <bug-commoncpp@gnu.org>; Fri, 22 Feb 2002 04:14:06 -0500
Received: (qmail 29764 invoked by uid 8); 22 Feb 2002 10:15:06 -0000
Received: from 212-41-210-71.adsl.galactica.it (212.41.210.71, claiming to be "MORDOR")
	by mail.syntrex.com with SMTP id smtpdZapyxG; Fri, 22 Feb 2002 05:15:01 EST
Date: Fri, 22 Feb 2002 10:13:52 +0100
From: Pavel Tsekov <ptsekov@syntrex.com>
X-Mailer: The Bat! (v1.53d) UNREG / CD5BF9353B3B7091
Reply-To: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex, Inc.
X-Priority: 3 (Normal)
Message-ID: <1981576266.20020222101352@syntrex.com>
To: bug-commoncpp@gnu.org
Subject: Re: Socket::isPending () issue
In-Reply-To: <2421959345.20020220153359@syntrex.com>
References: <2421959345.20020220153359@syntrex.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
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/>

Hey there :)

Does anyone red this message ? Any ideas ?

Wednesday, February 20, 2002, 3:33:59 PM, I wrote:

[ snip ]

PT> Now my question is - what's the purpose for this difference in the
PT> behaviour of isPending ().

Thanks :)



From flavio.oliveira@inttegra.com.br Fri Feb 22 09:51:30 2002
Received: from toole.uol.com.br ([200.231.206.186])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16eH2n-00083A-00
	for <bug-commoncpp@gnu.org>; Fri, 22 Feb 2002 09:51:30 -0500
Received: from DFCP0030 ([200.193.226.141])
	by toole.uol.com.br (8.9.1/8.9.1) with SMTP id LAA05941
	for <bug-commoncpp@gnu.org>; Fri, 22 Feb 2002 11:47:44 -0300 (BRT)
From: "Flavio Oliveira" <flavio.oliveira@inttegra.com.br>
To: <bug-commoncpp@gnu.org>
Subject: install common C++ 1.9.5
Date: Fri, 22 Feb 2002 11:52:39 -0300
Message-ID: <JLENJOAMOMNJCILEOGMJEEBMCBAA.flavio.oliveira@inttegra.com.br>
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700
Importance: Normal
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 tried install common C++ 1.9.5 and I was not able to install it:

I am using the Solaris 8.0, and I am trying to install the
CommonC++-1.9.5. I have the message when execute ./configure:

# ./configure
loading cache ./config.cache
checking host system type... sparc-sun-solaris2.8
checking target system type... sparc-sun-solaris2.8
checking build system type... sparc-sun-solaris2.8
checking for MSC environment... ./configure: cl: not found
no
checking for a BSD compatible install... config/install-sh -c
checking whether build environment is sane... configure:
error: newly created file is older than distributed files!
Check your system clock

I don't know how to compile with make, i type : /usr/ccs/bin/make
to compile the package, but which are the parameters?

Thank you, flavio.


From ptsekov@syntrex.com Fri Feb 22 10:18:04 2002
Received: from host202-pool801891.interbusiness.it ([80.18.91.202] helo=syntrex.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16eHSU-0001E8-00
	for <bug-commoncpp@gnu.org>; Fri, 22 Feb 2002 10:18:03 -0500
Received: (qmail 15027 invoked by uid 8); 22 Feb 2002 16:18:48 -0000
Received: from 212-41-210-71.adsl.galactica.it (212.41.210.71, claiming to be "MORDOR")
	by mail.syntrex.com with SMTP id smtpdNB2jSk; Fri, 22 Feb 2002 11:18:41 EST
Date: Fri, 22 Feb 2002 16:17:18 +0100
From: Pavel Tsekov <ptsekov@syntrex.com>
X-Mailer: The Bat! (v1.53d) UNREG / CD5BF9353B3B7091
Reply-To: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex, Inc.
X-Priority: 3 (Normal)
Message-ID: <16823381610.20020222161718@syntrex.com>
To: "Flavio Oliveira" <flavio.oliveira@inttegra.com.br>
CC: bug-commoncpp@gnu.org
Subject: Re: install common C++ 1.9.5
In-Reply-To: <JLENJOAMOMNJCILEOGMJEEBMCBAA.flavio.oliveira@inttegra.com.br>
References: <JLENJOAMOMNJCILEOGMJEEBMCBAA.flavio.oliveira@inttegra.com.br>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
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/>

Hello Flavio,

Friday, February 22, 2002, 3:52:39 PM, you wrote:

FO> I tried install common C++ 1.9.5 and I was not able to install it:

FO> I am using the Solaris 8.0, and I am trying to install the
FO> CommonC++-1.9.5. I have the message when execute ./configure:

FO> # ./configure
FO> loading cache ./config.cache
FO> checking host system type... sparc-sun-solaris2.8
FO> checking target system type... sparc-sun-solaris2.8
FO> checking build system type... sparc-sun-solaris2.8
FO> checking for MSC environment... ./configure: cl: not found
FO> no
FO> checking for a BSD compatible install... config/install-sh -c
FO> checking whether build environment is sane... configure:
FO> error: newly created file is older than distributed files!
FO> Check your system clock

FO> I don't know how to compile with make, i type : /usr/ccs/bin/make
FO> to compile the package, but which are the parameters?

What does 'make' has to do with configure - you fail on the configure
phase... So I suggest you to do exactly what the configure scrip
suggests you - check the time ... The time on the Solaris box and also
of the CommonC++ files.

Well, if this doesn't help go to line 833 of the configure script.
There is the test which on unsuccess shows this message. If you're
good enough in shellscripting - try to understand it :) If you're no
as I am - then remove the test itself :)

Maybe someone on the list will come up with a better solution though.
:)



From dyfet@ostel.com Fri Feb 22 14:08:21 2002
Received: from [65.204.5.82] (helo=andromeda.sys)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16eL3M-0005Ek-00
	for <bug-commoncpp@gnu.org>; Fri, 22 Feb 2002 14:08:20 -0500
Received: from ostel.com (localhost.localdomain [127.0.0.1])
	by andromeda.sys (8.11.4/8.11.4) with ESMTP id g1MJ7os18629;
	Fri, 22 Feb 2002 14:07:53 -0500
Message-ID: <3C769706.50602@ostel.com>
Date: Fri, 22 Feb 2002 14:07:50 -0500
From: David Sugar <dyfet@ostel.com>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.7) Gecko/20020107
X-Accept-Language: en-us
MIME-Version: 1.0
To: Pavel Tsekov <ptsekov@syntrex.com>
CC: bug-commoncpp@gnu.org, Frediano Ziglio <freddyz77@tin.it>
Subject: Re: Socket::isPending () issue
References: <2421959345.20020220153359@syntrex.com>
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/>

We had been a bit busy with the Common C++ "2" release, so I had not had 
a chance to think about this question until now...

Interuppted system calls can happen from signal handlers that have 
"sa_interrupt" set.  If one resumes the poll and there is data pending 
as well, the poll should then drop back out immediately and not keep 
looping.  However, there is no harm in examining the returned struct for 
pending data rather than looping right back.

In the case of select, I do not know why we did not do the same, but I 
think the immediate fallback loop in poll might be a mistake, as you 
point out.

Pavel Tsekov wrote:

>Hello :)
>
>I want to raise another issue witch have made be go crazy for the
>last few days :) On unices, based on your system a decision is made
>if poll () or select () will be used to check if network data is
>available for reading/writing. One would assume that using either of
>these will give him the same result - but not. The version of Socket::isPending
>() which uses poll () has an additional check - if the return value of
>poll is -1 then a check is made if errno is set to EINTR and if
>positive poll () is called again. This may result in an infinite loop.
>
>I have a code which sends data through a tcpstream instance. Before
>each write I do a Readline() with a timeout of 1000 milliseconds
>to see if the other end wants to inform me of something. This seemed
>to work fine though if I send a large amount of data (more than 5 Mb)
>I got struck buy this issue - at some point the code blocks in the
>isPending () and cannot get out of there. I solved the issue by using
>the version of isPending () which uses select ().
>
>Now my question is - what's the purpose for this difference in the
>behaviour of isPending ().
>
>Thanks ;)
>
>P.S. The system is: i386 runnning RedHat Linux 7.2 - everything is stock, no
>installation of custom packages.
>
>
>_______________________________________________
>Bug-commoncpp mailing list
>Bug-commoncpp@gnu.org
>http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>





From zedshaw@zedshaw.com Sat Feb 23 19:17:21 2002
Received: from amhi23eiy26i4.bc.hsia.telus.net ([64.180.190.235] helo=webapps.dnsalias.net)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16emLx-0001gq-00
	for <bug-commoncpp@gnu.org>; Sat, 23 Feb 2002 19:17:21 -0500
Received: from workhorse.killnine.net (unknown [192.168.1.60])
	by webapps.dnsalias.net (Postfix) with ESMTP id D9F51964F
	for <bug-commoncpp@gnu.org>; Sat, 23 Feb 2002 16:19:54 -0800 (PST)
Date: Sat, 23 Feb 2002 16:37:17 -0800
From: "Zed A . Shaw" <zedshaw@zedshaw.com>
To: bug-commoncpp@gnu.org
Subject: xml.o empty in 1.9.5 (Linux Mandrake, G++ 2.96 20000731)
Message-ID: <20020223163717.E2998@workhorse.killnine.net>
Reply-To: zedshaw@zedshaw.com
Mime-Version: 1.0
Content-Type: text/plain; format=flowed; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Mailer: Balsa 1.2.3
Lines: 44
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 just started evaluating CommonC++ for use in an application, and I 
like it a lot.  I ran into a weird problem though:  The object file 
xml.o (and all libraries it is in) is empty of any symbols.  I find 
this error when I attempt to compile the demo/xmlfetch.cpp file:

/bin/sh ../libtool --mode=link c++  -g -O2 -D_GNU_SOURCE -D_REENTRANT 
-D_THREAD_SAFE  -o xmlfetch  xmlfetch.o ../src/libccext.la  -lz 
../src/libccgnu.la -pthread -ldl
c++ -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -o .libs/xmlfetch 
xmlfetch.o ../src/.libs/libccext.so -lz ../src/.libs/libccgnu.so 
-pthread -ldl -Wl,--rpath -Wl,/usr/local/lib
xmlfetch.o: In function `myXMLParser::Close(void)':
/home/zedshaw/projects/CommonC++-1.9.5/demo/xmlfetch.cpp:116: undefined 
reference to `ost::XMLStream::Parse(char const *)'
collect2: ld returned 1 exit status
make: *** [xmlfetch] Error 1


All the other examples compile without any problems.  I thought this 
was strange, so I used nm -C to investigate the library file libccext.a 
and all that is in there is an empty entry for the xml.o file.  I 
investigated the src/xml.o file and nm -C reports the same thing: no 
functions, classes, nothing.

I tried removing the file and then re-making it with "make xml.o" and 
it still produces an object file with no entries.  The file does have a 
size though, of 81160 bytes.  When I open it with hexedit, it has 
contents in it.

I've attached the object file to this e-mail for you to review.  I'm 
thinking it may be a bug with G++, as it is kind of a strange thing to 
happen.  Please let me know what you think.

Here's the particulars of my machine and configuration:

* Linux  2.4.8-34.1mdk #1 Mon Nov 19 12:40:39 MST 2001 i686 unknown
* gcc version 2.96 20000731 (Mandrake Linux 8.1 2.96-0.62mdk)
* CommonC++ 1.9.5 downloaded from ftp.gnu.org

Thanks again.

Zed A. Shaw


From dyfet@ostel.com Sat Feb 23 22:10:05 2002
Received: from dsl-65-188-113-57.telocity.com ([65.188.113.57] helo=home.sys)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16ep36-0004JT-00
	for <bug-commoncpp@gnu.org>; Sat, 23 Feb 2002 22:10:04 -0500
Received: by home.sys (Postfix, from userid 501)
	id 1682130CDA; Sat, 23 Feb 2002 22:27:05 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
	by home.sys (Postfix) with ESMTP
	id 107A430CC4; Sat, 23 Feb 2002 22:27:05 -0500 (EST)
Date: Sat, 23 Feb 2002 22:27:05 -0500 (EST)
From: David Sugar <dyfet@ostel.com>
X-X-Sender:  <dyfet@home>
To: "Zed A . Shaw" <zedshaw@zedshaw.com>
Cc: <bug-commoncpp@gnu.org>
Subject: Re: xml.o empty in 1.9.5 (Linux Mandrake, G++ 2.96 20000731)
In-Reply-To: <20020223163717.E2998@workhorse.killnine.net>
Message-ID: <Pine.LNX.4.33L2.0202232225490.2554-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/>

xml.cpp only compiles when libxml2 has been installed.  Otherwise it
creates a placeholder empty object file just so the make doesn't give a
fit.  If you install gnome libxml2, remove the config.cache file, and
re-run "configure", you will have your missing xml support.

David

On Sat, 23 Feb 2002, Zed A . Shaw wrote:

> Hello,
>
> I just started evaluating CommonC++ for use in an application, and I
> like it a lot.  I ran into a weird problem though:  The object file
> xml.o (and all libraries it is in) is empty of any symbols.  I find
> this error when I attempt to compile the demo/xmlfetch.cpp file:
>
> /bin/sh ../libtool --mode=link c++  -g -O2 -D_GNU_SOURCE -D_REENTRANT
> -D_THREAD_SAFE  -o xmlfetch  xmlfetch.o ../src/libccext.la  -lz
> ../src/libccgnu.la -pthread -ldl
> c++ -g -O2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -o .libs/xmlfetch
> xmlfetch.o ../src/.libs/libccext.so -lz ../src/.libs/libccgnu.so
> -pthread -ldl -Wl,--rpath -Wl,/usr/local/lib
> xmlfetch.o: In function `myXMLParser::Close(void)':
> /home/zedshaw/projects/CommonC++-1.9.5/demo/xmlfetch.cpp:116: undefined
> reference to `ost::XMLStream::Parse(char const *)'
> collect2: ld returned 1 exit status
> make: *** [xmlfetch] Error 1
>
>
> All the other examples compile without any problems.  I thought this
> was strange, so I used nm -C to investigate the library file libccext.a
> and all that is in there is an empty entry for the xml.o file.  I
> investigated the src/xml.o file and nm -C reports the same thing: no
> functions, classes, nothing.
>
> I tried removing the file and then re-making it with "make xml.o" and
> it still produces an object file with no entries.  The file does have a
> size though, of 81160 bytes.  When I open it with hexedit, it has
> contents in it.
>
> I've attached the object file to this e-mail for you to review.  I'm
> thinking it may be a bug with G++, as it is kind of a strange thing to
> happen.  Please let me know what you think.
>
> Here's the particulars of my machine and configuration:
>
> * Linux  2.4.8-34.1mdk #1 Mon Nov 19 12:40:39 MST 2001 i686 unknown
> * gcc version 2.96 20000731 (Mandrake Linux 8.1 2.96-0.62mdk)
> * CommonC++ 1.9.5 downloaded from ftp.gnu.org
>
> Thanks again.
>
> Zed A. Shaw
>
> _______________________________________________
> Bug-commoncpp mailing list
> Bug-commoncpp@gnu.org
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp
>



From Video.C@dolphins.co.uk Mon Feb 25 10:27:36 2002
Received: from [211.144.168.22] (helo=dns.wesunway.com)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16fN2B-0001La-00; Mon, 25 Feb 2002 10:27:24 -0500
Received: from 192.168.0.3 by dns.wesunway.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.0.1460.8)
	id FJAM4NS2; Mon, 25 Feb 2002 17:50:32 +0800
From: "Video.C@dolphins.co.uk" <Video.C@dolphins.co.uk>
To: "9980@hotbot.com" <9980@hotbot.com>
Message-ID: <1014630722.0268631385@mail.dolphins.co.uk>
Subject: $ave money on your long distance conference calls
MIME-Version: 1.0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Date: Mon, 25 Feb 2002 10:27:24 -0500
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/>

<HTML><HEAD><TITLE>Take Control Of Your Conference Calls</TITLE>
<META http-equiv=3DContent-Type content=3D=22text/html; charset=3Dwindows-1=
252=22>
<META content=3D=22MSHTML 5.50.4134.600=22 name=3DGENERATOR></HEAD>
<BODY vLink=3D=23c0c0c0 link=3D=23c0c0c0 bgColor=3D=23FFFFFF leftMargin=3D0><F=
ONT 
face=3DTimes, New Roman>
<P>
<CENTER>
<TABLE width=3D600 border=3D0>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><B><FONT color=3D=23000066 size=3D6>Crystal Clear  
      Conference Calls<BR>Only <U>18 Cents</U> Per Minute=21</B></FONT><=
/TD></TR></TBODY></TABLE>
<P><FONT color=3D=23666600 size=3D5><B>(Anytime/Anywhere)</B></FONT> 
<P>
<TABLE width=3D350 border=3D0>
  <TBODY>
  <TR>
    <TD><FONT color=3D=23000066 size=3D3><B>
      <LI>No setup fees 
      <LI>No contracts or monthly fees 
      <LI>Call anytime, from anywhere, to anywhere 
      <LI>Connects up to 100 Participants 
      <LI>International Dial In 18 cents per minute
      <LI>Simplicity in set up and administration 
      <LI>Operator Help available 24/7 </B></FONT></LI></TD></TR></TBOD=
Y></TABLE>
<P>
<TABLE width=3D500 border=3D0>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><FONT color=3D=23666600 size=3D60><B><FONT size=3D5>G=
et the best 
      quality, the easiest to use, and lowest rate in the 
      industry.</B></FONT></FONT></TD></TR></TBODY></TABLE>
<P>
<TABLE width=3D400 border=3D0>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><FONT color=3D=23000066 size=3D4>If you like saving =
money, fill 
      out the form below and one of our consultants will contact 
  you.</FONT></TD></TR></TBODY></TABLE>
<P><FONT color=3D=23000066 size=3D2>Required Input Field<FONT color=3D=23666=
600 
size=3D2>*</FONT></FONT> 
<P>
<TABLE cellSpacing=3D0 borderColorDark=3D=23333300 cellPadding=3D3 width=3D6=
00 
borderColorLight=3D=23ffffcc>
  <TBODY>
  <TR>
    <TD align=3Dmiddle>
      <FORM action=3Dmailto:inbocks2_3=40yahoo.com?subject=3DConference_In=
quiry 
      method=3Dpost encType=3Dtext/plain>
      <TABLE width=3D=22100%=22>
        <TBODY>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066
          size=3D2>Name</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DNAME></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Web 
            Address</FONT></TD>
          <TD><INPUT value=3Dhttp:// name=3DURL></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Company 
            Name</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DCOMPANY_NAME></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>
            State</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT size=3D2 name=3DSTATE></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Business 
            Phone</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DBUS_PHONE></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Home 
            Phone</FONT></TD>
          <TD><INPUT name=3DHOME_PHONE></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Email 
            Address</FONT><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23666600 
            size=3D2>*</FONT></TD>
          <TD><INPUT name=3DEMAIL></TD></TR>
        <TR>
          <TD align=3Dright width=3D=2250%=22><FONT 
            face=3D=22Arial, Helvetica, sans-serif=22 color=3D=23000066 size=
=3D2>Type of 
            Business</FONT></TD>
          <TD><INPUT name=3DTYPE_OF_BUSINESS></TD></TR></TBODY></TABLE>
      <P><INPUT type=3Dsubmit value=3D=22Submit Information=22 name=3Dsubmit=
> 
    </FORM></P></TD></TR></TBODY></TABLE>
<BR><BR>
<TABLE width=3D500>
  <TBODY>
  <TR>
    <TD align=3Dmiddle><FONT face=3D=22Arial, Helvetica, sans-serif=22 colo=
r=3D=23666600
      size=3D1>c 1999-2002 CCFL <BR> To be removed from our distribution=
 lists, please  
      <A href=3D=22mailto:delete6_4=40yahoo.com?subject=3DRemove_Conferenci=
ng=22>Click 
      here.<FONT color=3D=23666600></A></FONT>.</FONT></TD></TR></TBODY><=
/TABLE></P></CENTER></BODY></HTML>

*******


From flavio.oliveira@inttegra.com.br Mon Feb 25 13:49:49 2002
Received: from ginsberg.uol.com.br ([200.231.206.26])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16fQC5-00065z-00
	for <bug-commoncpp@gnu.org>; Mon, 25 Feb 2002 13:49:49 -0500
Received: from DFCP0030 ([200.163.17.222])
	by ginsberg.uol.com.br (8.9.1/8.9.1) with SMTP id PAA19620;
	Mon, 25 Feb 2002 15:48:41 -0300 (BRT)
From: "Flavio Oliveira" <flavio.oliveira@inttegra.com.br>
To: <zedshaw@zedshaw.com>, <bug-commoncpp@gnu.org>
Subject: XML e FTP
Date: Mon, 25 Feb 2002 15:47:22 -0300
Message-ID: <JLENJOAMOMNJCILEOGMJEECLCBAA.flavio.oliveira@inttegra.com.br>
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
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.2919.6700
In-Reply-To: <20020223163717.E2998@workhorse.killnine.net>
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,

which are main the directive of compilation to construct applications 
that use the libraries of xml and ftp?  

Thanks Flavio.



From test@test.com Tue Feb 26 12:48:26 2002
Received: from delysid.gnu.org ([158.121.106.20])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16fliD-0002Mf-00
	for <bug-commoncpp@gnu.org>; Tue, 26 Feb 2002 12:48:25 -0500
Received: from [211.217.173.10] (helo=localhost)
	by delysid.gnu.org with smtp (Exim 3.34 #2)
	id 16fliA-00028F-00
	for <bug-commoncpp@gnu.org>; Tue, 26 Feb 2002 12:48:22 -0500
Reply-To: gotours@dreamwiz.com
From: 여행가자<test@test.com>
To: bug-commoncpp@gnu.org
Subject: [이벤트광고]무료 회원가입 하시면 해외 무료 여행권을 드립니다.
Mime-Version: 1.0
Content-Type: text/html; charset="ks_c_5601-1987"
Date: Wed, 27 Feb 2002 02:46:08 +0900
Message-Id: <E16fliA-00028F-00@delysid.gnu.org>
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/>

<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
<title>여행가자 오픈 기념으로 회원 가입시 [태국,필리핀,사이판] 무료 해외 여행권을 드립니다.</title>
<meta name="generator" content="Namo WebEditor v5.0">
</head>
<body bgcolor="white" text="black" link="blue" vlink="purple" alink="red">
<table align="center" cellpadding="0" cellspacing="0" width="600">
<tr>
<td width="974">
<p align="center"><img src="http://my.dreamwiz.com/merzone/6.jpg" width="600" height="152" border="0" usemap="#ImageMap1"></p>
</td>
</tr>
<tr>
<td width="974">
<p align="center"><a href="http://www.honeymoonbest.com" target="_blank"><img src="http://my.dreamwiz.com/merzone/7.jpg" width="600" height="170" border="0"></a></p>
</td>
</tr>
<tr>
<td width="974" height="255">
<p align="center"><a href="http://www.honeymoonbest.com" target="_blank"><img src="http://my.dreamwiz.com/merzone/3.jpg" width="600" height="254" border="0"></a></p>
</td>
</tr>
<tr>
<td width="974">
<p align="center"><a href="http://www.honeymoonbest.com" target="_blank"><img src="http://my.dreamwiz.com/merzone/4.jpg" width="600" height="221" border="0"></a></p>
</td>
</tr>
<tr>
<td width="974">
<p align="center"><img src="http://my.dreamwiz.com/merzone/5.jpg" width="600" height="83" border="0"></p>
</td>
</tr>
<tr>
<td width="974">
<P align=center><span style="FONT-SIZE: 9pt"><br></span><span style="FONT-SIZE: 10pt"
><b><font color="blue">[이벤트1] = 여행가자 홈페이지 오픈 기념으로 회원 가입시 [태국,필리핀,사이판] <BR>무료
해외 여행권을 드립니다.&nbsp;&nbsp; [<FONT color=#ff0080>항공권 별도</FONT>
]<br>기간 : 2002년 2월18일 ~ 4월 30일 까지 대상 : 여행가자 신규회원 가입자
전원증정<BR><BR>[이벤트2] =
주위의&nbsp;결혼하시는&nbsp;분들에게&nbsp;저희&nbsp;여행가자를&nbsp;소개시켜&nbsp;주셔서&nbsp;신혼여행이&nbsp;<BR>계약되면&nbsp;계약과&nbsp;동시에&nbsp;계좌로&nbsp;일금&nbsp;50,000원을&nbsp;입금해&nbsp;드립니다.<BR>(단&nbsp;제주도&nbsp;신혼여행은&nbsp;20,000원)&nbsp;</font></b></span><span style="FONT-SIZE: 9pt"><br></span><span style="FONT-SIZE: 12pt"
><b><a href="http://www.honeymoonbest.com" target="_blank">&nbsp;여행가자
홈페이지 바로가기</a><br>&nbsp;</b></span></P>
</td>
</tr>
<tr>
<td width="974"> <p> <span style="FONT-SIZE: 10pt"
><b>귀하의 승락없이 홍보성 전자 우편을 보내게 된 점 정중히 사과 드립니다.<BR>정보통신망이용촉진법 규정을 준수하여 광고메일임을 표시하였으며, 수신거부 장치를 마련하고 있습니다.<BR>귀하의 전자 우편 주소는 인터넷 상의
공개된 장소에서 습득하였으며, 저희는 귀하의 전자우편 주소 외 어떠한 개인정보도 가지고 있지 않으므로 안심하시기 바랍니다. 수신을 원치 않으시면 </b></span><A href="mailto:gotour@hanmir.com"><span style="FONT-SIZE: 10pt"
><b><IMG align=absMiddle border=0 height=21
src="http://my.dreamwiz.com/merzone/Btn_opt_out.gif"
width=57></b></span></A><span style="FONT-SIZE: 10pt"
><b>
를 클릭해 주십시요. &nbsp;</b></span></p>
</td>
</tr>
<tr>
<td width="974">
<p>&nbsp;</p>
</td>
</tr>
</table>
<map name="ImageMap1">
<area shape="RECT" coords="346,27,570,60" href   ="http://www.honeymoonbest.com" target="_blank">
</map>
</body>
</html>


From gnguyen1718@earthlink.net Thu Feb 28 03:44:01 2002
Received: from [203.162.50.107] (helo=master.vdi.com.vn)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16gMAS-0001oz-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 03:44:01 -0500
Received: from THAOXP ([172.16.99.99]) by master.vdi.com.vn with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.1960.3)
	id FXMF86R0; Thu, 28 Feb 2002 15:44:33 +0700
Message-ID: <003801c1c034$3058e890$636310ac@thaoxp>
Reply-To: "gnguyen" <gnguyen1718@earthlink.net>
From: "gnguyen" <gnguyen1718@earthlink.net>
To: <bug-commoncpp@gnu.org>
Date: Thu, 28 Feb 2002 15:44:47 +0700
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----=_NextPart_000_0035_01C1C06E.D9DBC9C0"
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
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_0035_01C1C06E.D9DBC9C0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi,
I am beginer with linux programming. I want to using CommonC++-1.9.5 =
library under RedHat linux 7.2. But I don't known link my project with =
CommonC++ library. How to link this library into my program.=20
I have read a following sentence :

[Makefile.am]

EXTRA_DIST=3Dccgnu-config.in ccgnu-config ost_check.m4 Makefile.bcc
LT_VERSION=3D@LT_CCXX_VERSION@
CXXFLAGS =3D -I../src @CXXFLAGS@ $(THREAD_FLAGS)
CFLAGS =3D @CFLAGS@ $(THREAD_FLAGS)
INCLUDES =3D -I$(CCXX_DIR) @XML_FLAGS@
LDFLAGS =3D @LDFLAGS@ $(LT_VERSION) -release $(LT_RELEASE)
ccxxincludedir=3D$(includedir)/cc++
...

What it's mean?
If I wanted to use KDevelop, I would set how to parameter option =
project.
Thanks for helping me.

------=_NextPart_000_0035_01C1C06E.D9DBC9C0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV>
<DIV><FONT face=3DArial size=3D2>Hi,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I am beginer with linux programming. I =
want to=20
using CommonC++-1.9.5 library&nbsp;under RedHat linux 7.2. But I don't =
known=20
link my project with CommonC++ library. How to link this library into my =

program. </FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I have read a following sentence =
:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>[Makefile.am]</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>EXTRA_DIST=3Dccgnu-config.in =
ccgnu-config=20
ost_check.m4 Makefile.bcc<BR><A=20
href=3D"mailto:LT_VERSION=3D@LT_CCXX_VERSION">LT_VERSION=3D@LT_CCXX_VERSI=
ON</A>@<BR>CXXFLAGS=20
=3D -I../src @CXXFLAGS@ $(THREAD_FLAGS)<BR>CFLAGS =3D @CFLAGS@=20
$(THREAD_FLAGS)<BR>INCLUDES =3D -I$(CCXX_DIR) @XML_FLAGS@<BR>LDFLAGS =3D =
@LDFLAGS@=20
$(LT_VERSION) -release=20
$(LT_RELEASE)<BR>ccxxincludedir=3D$(includedir)/cc++</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>...</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>What it's mean?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>If I wanted to use KDevelop, I would =
set how=20
to&nbsp;parameter option project.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Thanks for helping=20
me.</FONT></DIV></DIV></BODY></HTML>

------=_NextPart_000_0035_01C1C06E.D9DBC9C0--



From hieuthao@vdi-tech.com Thu Feb 28 03:48:37 2002
Received: from [203.162.50.107] (helo=master.vdi.com.vn)
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16gMEt-0001zP-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 03:48:37 -0500
Received: from THAOXP ([172.16.99.99]) by master.vdi.com.vn with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.1960.3)
	id FXMF86SD; Thu, 28 Feb 2002 15:49:28 +0700
Message-ID: <005701c1c034$e022bd50$636310ac@thaoxp>
Reply-To: "Hieu Thao" <hieuthao@vdi-tech.com>
From: "Hieu Thao" <hieuthao@vdi-tech.com>
To: <bug-commoncpp@gnu.org>
Subject: Linking CommonC++-1.9.5 into my project under Redhat 7.2
Date: Thu, 28 Feb 2002 15:49:41 +0700
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----=_NextPart_000_0052_01C1C06F.893F3B90"
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
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_0052_01C1C06F.893F3B90
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi,
I am beginer with linux programming. I want to using CommonC++-1.9.5 =
library under RedHat linux 7.2. But I don't known link my project with =
CommonC++ library. How to link this library into my program.=20
I have read a following sentence :

[Makefile.am]

EXTRA_DIST=3Dccgnu-config.in ccgnu-config ost_check.m4 Makefile.bcc
LT_VERSION=3D@LT_CCXX_VERSION@
CXXFLAGS =3D -I../src @CXXFLAGS@ $(THREAD_FLAGS)
CFLAGS =3D @CFLAGS@ $(THREAD_FLAGS)
INCLUDES =3D -I$(CCXX_DIR) @XML_FLAGS@
LDFLAGS =3D @LDFLAGS@ $(LT_VERSION) -release $(LT_RELEASE)
ccxxincludedir=3D$(includedir)/cc++
...

What it's mean?
If I wanted to use KDevelop, I would set how to parameter option =
project.
Thanks for helping me.

------=_NextPart_000_0052_01C1C06F.893F3B90
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV>
<DIV>
<DIV><FONT face=3DArial size=3D2>Hi,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I am beginer with linux programming. I =
want to=20
using CommonC++-1.9.5 library&nbsp;under RedHat linux 7.2. But I don't =
known=20
link my project with CommonC++ library. How to link this library into my =

program. </FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I have read a following sentence =
:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>[Makefile.am]</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>EXTRA_DIST=3Dccgnu-config.in =
ccgnu-config=20
ost_check.m4 Makefile.bcc<BR><A=20
href=3D"mailto:LT_VERSION=3D@LT_CCXX_VERSION">LT_VERSION=3D@LT_CCXX_VERSI=
ON</A>@<BR>CXXFLAGS=20
=3D -I../src @CXXFLAGS@ $(THREAD_FLAGS)<BR>CFLAGS =3D @CFLAGS@=20
$(THREAD_FLAGS)<BR>INCLUDES =3D -I$(CCXX_DIR) @XML_FLAGS@<BR>LDFLAGS =3D =
@LDFLAGS@=20
$(LT_VERSION) -release=20
$(LT_RELEASE)<BR>ccxxincludedir=3D$(includedir)/cc++</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>...</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>What it's mean?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>If I wanted to use KDevelop, I would =
set how=20
to&nbsp;parameter option project.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Thanks for helping=20
me.</FONT></DIV></DIV></DIV></BODY></HTML>

------=_NextPart_000_0052_01C1C06F.893F3B90--



From hanbay3@hotmail.com Thu Feb 28 08:23:12 2002
Received: from [211.215.146.9] (helo=hotmail.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16gQWd-0001ky-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 08:23:11 -0500
Reply-To: hanbay3@hotmail.com
From: HanBay <hanbay3@hotmail.com>
To:  <bug-commoncpp@gnu.org>
Subject: [광 고] 해외교포들의 한국식품 종합쇼핑몰
Mime-Version: 1.0
Content-Type: text/html; charset="ks_c_5601-1987"
Date: Thu, 28 Feb 2002 22:20:13 +0900
Message-Id: <E16gQWd-0001ky-00@fencepost.gnu.org>
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/>

<!-- saved from url=(0022)http://internet.e-mail -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>:+: 한베이 홍보메일 :+:</TITLE>
<META content="text/html; charset=euc-kr" http-equiv=Content-Type>
<META content="MSHTML 5.00.2614.3500" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff leftMargin=0 text=#000000 topMargin=0>
<TABLE bgColor=#666666 border=0 cellPadding=0 cellSpacing=1>
  <TBODY>
  <TR>
    <TD bgColor=#ffffff>
      <TABLE border=0 cellPadding=0 cellSpacing=0>
        <TBODY>
        <TR>
          <TD><A href="http://www.hanbay.com/" target=_blank><IMG border=0 
            height=224 src="http://hanbay.com/image/advertise_01.gif" 
          width=555></A></TD></TR>
        <TR>
          <TD><A href="http://www.hanbay.com/" target=_blank><IMG border=0 
            height=106 src="http://hanbay.com/image/advertise_02.gif" 
          width=555></A></TD></TR>
        <TR>
          <TD><A href="http://www.hanbay.com/" target=_blank><IMG border=0 
            height=17 src="http://hanbay.com/image/full.gif" width=555></A></TD></TR>
        <TR>
          <TD><A href="http://www.hanbay.com/" target=_blank><IMG border=0 
            height=265 src="http://hanbay.com/image/advertise_04.gif" 
          width=555></A></TD></TR>
        <TR>
          <TD><A href="http://www.hanbay.com/" target=_blank><IMG border=0 
            height=20 src="http://hanbay.com/image/full.gif" width=555></A></TD></TR>
        <TR>
          <TD height=73><IMG height=67 
            src="http://hanbay.com/image/advertise_06.gif" width=555></TD></TR>
        <TR>
          <TD height=7></TD></TR>
        <TR>
          <TD>
            <DIV align=left><SPAN 
            style="FONT-SIZE: 9pt; FONT-FAMILY: 굴림; mso-hansi-font-family: Arial; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: KO; mso-bidi-language: AR-SA">+ 
            클릭하시면 바로 저희 자료에서 귀하의 이메일 주소가 삭제됩니다<SPAN lang=EN-US><SPAN 
            style="mso-spacerun: yes">&nbsp;&nbsp; </SPAN></SPAN></SPAN><SPAN 
            style="FONT-SIZE: 9pt; FONT-FAMILY: 굴림">☞ <A HREF="http://aproga.com/maildeny/maildeny.html?from=hanbay">수신거부</A></DIV></SPAN></TD></TR>
        <TR>
          <TD>&nbsp;</TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>


From mailmaster@personaldb.net Thu Feb 28 12:41:16 2002
Received: from [211.38.46.5] (helo=mail.personaldb.net)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16gUYK-0007cb-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 12:41:13 -0500
Received: (qmail 8459 invoked by alias); 28 Feb 2002 17:34:13 -0000
Received: from unknown (HELO personaldbmain1) (211.38.46.2)
  by mail.personaldb.net with SMTP; 28 Feb 2002 17:34:13 -0000
Reply-To: =?ks_c_5601-1987?B?sPy4rsDa?= <mailmaster@PersonalDB.net>
From: =?ks_c_5601-1987?B?sPy4rsDa?= <mailmaster@PersonalDB.net>
Bcc: 
Subject: =?ks_c_5601-1987?B?UGVyc29uYWxEQi5uZXQgyLi/+MC4t84gw8q067newLi8zA==?=
	=?ks_c_5601-1987?B?vcC0z7TZLiBbyKsgILq4XQ==?=
Date: Fri, 1 Mar 2002 02:37:03 +0900
Message-ID: <98f001c1c07e$88def550$0100000a@personaldbmain1>
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----=_NextPart_000_98F1_01C1C0C9.F8C69D50"
X-Mailer: Microsoft CDO for Windows 2000
Thread-Index: AcHAfojcFb56JxFlTyqwGZ1NKwFq6g==
Content-Class: urn:content-classes:message
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4807.1700
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_98F1_01C1C0C9.F8C69D50
Content-Type: text/plain;
	charset="ks_c_5601-1987"
Content-Transfer-Encoding: base64

IAkNCgkNClBlcnNvbmFsREK0wiC79bfOv+4gsLPAziDB9r3EILnXIMGkuriw/LiuIL3DvbrF28DU
tM+02S4NClBlcnNvbmFsREK/zSDH1LKyILv1t86/7iDBpLq4yK0gvLyw6LfOILOqvsawocH2IL7K
wLi9w7DavcC0z7HuPwkNCgkNCiAJDQoNClRvLiBidWctY29tbW9uY3BwILTUsrINClBlcnNvbmFs
REIubmV0IMi4v/jAuLfOIMPKtOu53sC4vMy9wLTPtNkuIFvIqyC6uF0NCg0KRnJvbS4gwKWw/Liu
wNogKCBtYWlsbWFzdGVyICkgIA0KICBfX19fXyAgDQoNCiAJDQoNCgm+yLPnx8+8vL/kLiC4uLOq
ILrLsNQgtce+7iC53bCpvcC0z7TZLg0KCQ0KCbq7ILvnwMzGrrTCIMi/wLLA+8C4t84gwNq9xcDH
IMH2vcSw+iDBpLq4LCDA2rfhtenAuyCw/Liux8+45yDAzLevx9EgwNq34bimIMSjsbi16bD6ILD4
wK/Hz7DFs6ogyKjG5MDMwfa/oSCw1L3DLA0Ktse0wiDB9r3Ew6Kw7b+hvK0gxse4xcfSILz2IMDW
tMIgu/W3zr/uIL3DvbrF28DUtM+02S4NCgkNCgmxzcfPsrK8rSC/qbevIMDat+GzqiDB9r3EwLsg
sK6w7SCw6L3DtNm46SDA+sjxv80gx9SysiDHz73DseK4piC52bb4tM+02S4NCgmxzcfPsrK8rSDG
r8GkutC+38DHIMD8ua6wobOqILjFtM++xr3DtvO46SDA+sjxv80gx9SysiDHz73DseK4piC52bb4
tM+02S4NCgmxzcfPsrK8rSC/qbevIMGkuri4piDDo7DtILDovcW02bjpIMD6yPG/zSDH1LKyIMfP
vcOx4rimILnZtvi0z7TZLg0KCbHNx8+ysrytIL+pt68gwNq34bXpuKYgxKOxuLOqILW/t+G16bD6
ILD4wK/Hz7DtIL3NwLi9w7jpIMD6yPG/zSDH1LKyIMfPvcOx4rimILnZtvi0z7TZLg0KCbHNx8+y
srytILHNx8+/zSCxzcfPwMcgxKO/7LXpuLjAxyC/wrbzwM4guPDA08C7ILCusO0gvc3AuL3DtNm4
6SDA+sjxv80gx9SysiDHz73DseK4piC52bb4tM+02S4NCgmxzcfPsrK8rSCxzcfPwMcgwfa9xMC4
t84guMW/+SDAz8Gkx9EgvPbA1MC7IL7ysO0gvc3AuL3DuOkgwPrI8b/NIMfUsrIgx8+9w7HiuKYg
udm2+LTPtNkuDQoJsc3Hz7KyvK0gyKjG5MDMwfa4piCwrrDtILDovcOwxbOqIMioxuTAzMH2uKYg
uLi15b3HIL+5waTAzLjpIMD6yPG/zSDH1LKyIMfPvcOx4rimILnZtvi0z7TZLg0KCbHNx8+ysryt
IMi4u+e/zSDB/SwgUEO55rXuIL+pt68gwOW80r+hvK0gxMTHu8XNuKYgu+e/68fPvcW02bjpIMD6
yPG/zSDH1LKyIMfPvcOx4rimILnZtvi0z7TZLg0KCQ0KCcCnwMcgwfa9xLD8uK4gwMy/3L+htbUg
uLnAuiC8rbrxvbqwoSDBprD4tce45yC8rbrxvbq0wiCw6LzTIMiutOu1x7DtIMDWvcC0z7TZLg0K
CQ0KCbChwNTAuiC5q7fhwNS0z7TZLg0KCQ0KCcbtwfawoSCxzcfPv80gx9SysiC79bfOv+4gwfa9
xCzBpLq4yLC1v8C7IMfSILz2IMDWtMIgwNvAuiDAzr+swMwgtckgvPYgwNax5iDB+L3JwLi3ziC5
2bbzuOcsIMfjtvS++MDMILq7DQq43sDPwLsgurizvbWlILTrx8+/qSDBy7zbvbq3sSC4tsC9wLsg
sd3H0iC89iC++L3AtM+02S4NCgm+1cC4t84gw9+wobXHtMIgvK268b26v80gte63z7XHtMIgv6m3
ryC/7Lz2x9EgwNq34bXpv6EgsPzH0SDBpLq4uKYgwaaw+MfYILXluLEgv7nBpMDUtM+02bi4ILi4
wM8gwPrI8SC758DMxq63zrrOxc0NCrjewM/AuyC53sH2IL7KseK4piC/+MfPvcO0wiCw5r/sIL7G
t6HAxyC89r3FsMW6zrimILvnv+vHz73HILz2IMDWvcC0z7TZLg0KCQ0KCbCou+fH1bTPtNkuDQoN
CiA8aHR0cDovL3d3dy5QZXJzb25hbERCLm5ldD4gCQ0KCQ0KCQ0KCQ0KIFBlcnNvbmFsREK0wj8J
DQogCQ0KCQ0KIAkNCgkNCiCws8DOtfC68QktIMDat+HAxyC6uLD8LCCw+MCvLCC4xbjFuKYgwKfH
0SCws8DOREIgwaaw+A0KLSCws8DOwNq34b3HLCCws8DOvtm5/CwgsLPAzrrPuLbFqbfOILG4vLoN
Ci0guriw/L/rLMioxuTAzMH2ILDUvcMswNq34bD4wK8swfa9xMOisO2/obytwMcgxse4xb/rwLi3
ziDIsL/rCQ0KCQ0KILCzwM618LrxCS0gvbrEycHZt68sIMDPseLA5SwguN648MDlLCBUbyBEbyBM
aXN0LCCws8DOwda80rfPLi4uDQotILCzwM7BpLq4sPy4rr+hIMfKv+TH0SC48LXnILCzwM68rbrx
vbogwaaw+A0KLSDG7biux8+w7SCwrbfCx9EgtOu/67euIMbEwM/A/LzbILytuvG9ug0KLSC48LXn
ILytuvG9usDat+G0wiC02b7nx8+w1CDIsL/rtcoJDQoJDQogsLPAzrXwuvEJLSC+xr/0t+jAxyCx
4rTJwLsguPC1ziDApcC4t84NCi0gsK23wsfPsO0gxu24rsfRIMH4waTH0SDApbjewM8NCi0gtfC3
usXkuK6w/LiuLLz2vcWwxbrOwbawxyy6zsDnwd/AwLTkLFBPUMH2v/i17iCwrbfCx9EgseK0yQkN
CgkNCiCws8DOtfC68QktILjwtecgyLi/+ERCwMcgutC3+bqwILjwwL0NCi0gwPy5rrChxNqzyiwg
USZBILXuwMcgtNm+58fRIMH2vcS9wLXmuea5/Q0KLSDIuL/4ILCzwM7B9r3ELCDA2rfhwMcgxse4
xbChILChtMkNCi0gsKIgyLi/+LXpwMcgwPy5rrDUvcPGx7jwwL3AuLfOILTZvufH0SDA2rfhIL3A
teawobTJCQ0KCQ0KILCzwM618LrxCS0gyKjG5MDMwfYguLa5/bvnt84gsKO03MfRILG4vLogsKG0
yQ0KLSDGxMDPuMW0z8D6t84gwKW787+hvK0gu+jBpiwgvvcvtNm/7rfOteUsILz2waQgsKG0yQ0K
LSCws8DORELA2rfhwMcgwNq1v773taXAzMauILHitMnAuLfOILD8uK4gsKPG7Q0KLSCw+MH2u+fH
1ywgsNS9w8bHLCC55rjtt88sIMSrv+7FzbXuILTZvufH0SC6zrChvK268b26CQ0KCQ0KILCzwM61
8LrxCS0gxvO84rzSuPDA07D6ILD4sLO80rjwwNPAuLfOILG4utANCi0gsLPAzkRCwMcgsPjAryCw
obTJDQotILD4wfa758fXLCCw1L3DxscsIMDat+G9xywgyLi/+MHWvNK3z7XuILTZvufH0SC8rbrx
vbogwaaw+AkNCgkNCiC+7rayutC/obDUIMfKv+TH0rHuv+Q/CQ0KIAkNCgkNCioJwf0sIMfQsbMs
IMi4u+csIFBDuea17iC/qbevIMDlvNK/obytIFBDuKYgu+e/68fPtMIgutAgDQoqCb7utrIgutC+
38DHIMDat+G4piC48MC4vcOwxbOqILi5wMwgurjAr8fPsO0gsOi9xSC60CANCioJx9EgutC+38DH
IMD8ua6wocDMsMWzqiC4xbTPvsbAzL3FILrQIA0KKgnB37/kx9EgwNq34bimILq4sPzH2L7fIMfP
tMIgutAgDQoqCcDavcXAxyDB9r3EwMyzqiDBpLq4LCDA2rfht84guMW/+SC89sDNwLsgv8O4rrDt
IL3NwLi9xSC60CANCioJx8q/5MfRIMH2vcTAzLOqIMGkuri4piDDo77GIMClvK3HzsC7IMDawdYg
x8+9w7TCILrQIA0KKgnGr8Gkx9EgutC+37+hILTrx8+/qSDA/LmusKHAxyC1tb/ywMwgx8q/5MfP
vcUgutAgDQoqCcSjsbizqiC1v7fhtemw+iDA2rfhuKYgsbPIryyw+MCvx9Igx8q/5LChIMDWwLi9
xSC60CANCioJyKjG5MDMwfa4piCwrrDtIMDWsMWzqiC4uLXpt8Gw7SDHz73DtMIgutAgDQoqCcio
xuTAzMH2uKYgsK6w7SDA1sH2uLggsPy4rsfPtMIgtaW/oSC+7rfBv/LAuyC0wLOisMWzqiCxzcL6
wLi9xSC60CANCioJxKOxuCwgtb/Doiwgtb+34bXusPogv+y4rri4wMcguPDA08C7ILi4temw7SC9
zcC4vcUgutC16SANCioJvu62siDB1sGmv6EgtOvHz7+pIL+pt68gu+e297XpsPrAxyC48MDTwMwg
x8q/5MfPvcUgutC16SANCioJwM+x4iy43rjwwOUsvbrEycHZt6+17iC/qbevILCzwM68rbrxvbq4
piDAzL/rx8+w7SC9zcC4vcUgutAgDQoqCcbtuK7Hz7DtILCtt8LH0SDA/MDav+zG7cDMIMfKv+TH
z73FILrQIA0KKgmwocG3LMSjsbgstb+34b/NwMcgu+fB+MC7IMD8wNq+2bn8wLi3ziDBpsDbx8+w
7SC9zcC4vcUgutAgDQoqCbmrvvm6uLTZtbUgw7yw6MD7wMy45yDIv7D6wPvAziDB9r3EsObA77fC
wLsgsK7D37DtIL3NwLi9xSC60A0KDQoNCgkNCsDMt7EgutC16cC6IL7uvK0gsKHA1MfPvLy/5C4g
u/W3zr/uILytuvG9urimILTAs6K9xyC89iDA1r3AtM+02S4gCQ0KCQ0KILChwNS68b/rILnXIMDM
v+u34bTCPwkNCiAJDQoJDQq5sLfQILChwNSw+iDAzL/rt+G0wiC5q7fhwNS0z7TZLg0KtNzB9iCw
ocDUx8+9w7HiuLggx8+46SDAp8DHILjwtecgvK268b26uKYgwMy/68fPvccgvPYgwNa9wLTPtNku
DQrHz8H2uLgguLnAuiC/67eusPogxq+6sMfRIMf9xcPAuyC/+MfPvcO0wiC60LXpwLsgwKfHz7+p
IMfBuK65zL72yLi/+MGmtbW4piC/7r+1x8+w7SDA1r3AtM+02S4NCsfBuK65zL72yLi/+MC4t84g
sKHA1MfPvcO46SDA+rfFx9EgsKGw3cC4t84gw+a60MfRIL/rt66w+iDH1LKyIMH2vcTDorDtv6G8
rcDHILjFuMWzqiDEwcXZw/exuMDUvcMgxq+6sMfRIMf9xcPAuyC15biztM+02S4NCsfBuK65zL72
yLi/+MC4t84gsKHA1C4uLiDB9rrStce0wiC68b/ruri02SC4ucC6IMDMwM3AzCDIuL/4v6m3r7rQ
srIgtbm+xrCptM+02S4NCsH2sd0gsKHA1MfPvLy/5CAJDQoJDQogPGh0dHA6Ly93d3cuUGVyc29u
YWxEQi5uZXQ+IAkNCkNvcHlyaWdodCCozzIwMDEgUGVyc29uYWxEQi5uZXQgQWxsIHJpZ2h0cyBy
ZXNlcnZlZC4gV2l0aCBRdWVzdGlvbnMsDQpwbGVhc2UgRS1tYWlsIHVzIDxodHRwOi8vd3d3LlBl
cnNvbmFsREIubmV0L2RlZmF1bHQuYXNwP2RpcmVjdD1hc2suaHRtPg0KfCC89r3FsMW6zg0KPGh0
dHA6Ly93d3cucGVyc29uYWxkYi5uZXQvbGliL3JlamVjdF9tYWlsLmFzcD9hZGRyPWJ1Zy1jb21t
b25jcHBAZ251Lm9yDQpnPiAgCQ0K

------=_NextPart_000_98F1_01C1C0C9.F8C69D50
Content-Type: text/html;
	charset="ks_c_5601-1987"
Content-Transfer-Encoding: base64

PGh0bWw+DQo8aGVhZD4NCiAgPHRpdGxlPlBlcnNvbmFsREIgvNKwsyC43sDPPC90aXRsZT4NCiAg
PG1ldGEgaHR0cC1lcXVpdj0iQ29udGVudC1MYW5ndWFnZSIgY29udGVudD0ia28iPg0KICA8bWV0
YSBodHRwLWVxdWl2PSJDb250ZW50LVR5cGUiIGNvbnRlbnQ9InRleHQvaHRtbDsgY2hhcnNldD1r
c19jXzU2MDEtMTk4NyI+DQogIDxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+DQogIDwhLS0NCiAgCSAg
LnRlbXAgeyAgQ09MT1I6ICM0NzQ3NDc7ICBmb250LWZhbWlseTq1uL/yOyBmb250LXNpemU6MTBw
dDsgIHRleHQtYWxpZ246Y2VudGVyIDsgfQ0KCSAgdGQge2ZvbnQtc2l6ZToxMHB0O2ZvbnQtZmFt
aWx5OrW4v/I7Y29sb3I6IzMzMzMzM30NCiAgICAgIGxpIHtjb2xvcjojMzMzMzMzO2xpc3Qtc3R5
bGUtdHlwZTpzcXVhcmV9DQogICAgICAgQTpsaW5rIHt0ZXh0LWRlY29yYXRpb246IG5vbmU7fQ0K
ICAgICAgIEE6dmlzaXRlZCB7dGV4dC1kZWNvcmF0aW9uOiBub25lO30NCiAgLS0+DQogIDwvc3R5
bGU+DQo8L2hlYWQ+DQo8Ym9keSBsZWZ0bWFyZ2luPTAgdG9wbWFyZ2luPTIwIGJnY29sb3I9I0Y3
RjdGNz4NCjxkaXYgYWxpZ249Y2VudGVyPg0KPHRhYmxlIGJvcmRlcj0wIGNlbGxwYWRkaW5nPTAg
Y2VsbHNwYWNpbmc9MCB3aWR0aD02MDAgPg0KCTx0cj48dGQgd2lkdGg9MTAwJT48aW1nIHNyYz0i
aHR0cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC9wZXJzb25hbGRiX3VwcGVyLmdpZiI+PC90ZD48
L3RyPg0KCTx0cj48dGQgaGVpZ2h0PTIwPjwvdGQ+PC90cj4NCgk8dHI+PHRkIGFsaWduPWNlbnRl
cj5QZXJzb25hbERCtMIgPEI+u/W3zr/uILCzwM4gwfa9xCC51yDBpLq4sPy4riC9w726xds8L0I+
wNS0z7TZLjxicj4NCgkJCVBlcnNvbmFsREK/zSDH1LKyILv1t86/7iDBpLq4yK0gvLyw6LfOILOq
vsawocH2IL7KwLi9w7DavcC0z7HuPzwvdGQ+PC90cj4NCiAgICA8dHI+PHRkIGhlaWdodD0yMD48
L3RkPjwvdHI+DQogICAgPHRyPjx0ZCBhbGlnbj1jZW50ZXI+DQogICAgICAgICAgICA8dGFibGUg
Ym9yZGVyPTAgY2VsbHBhZGRpbmc9MCBjZWxsc3BhY2luZz0wIHdpZHRoPTUwMD4NCiAgICAgICAg
ICAgICAgICA8dHIgdmFsaWduPSd0b3AnPg0KICAgICAgICAgICAgICAgICAgICA8dGQgY29sc3Bh
bj0nMic+DQogICAgICAgICAgICAgICAgICAgICAgICA8dGFibGUgYm9yZGVyPTAgY2VsbHBhZGRp
bmc9MCBjZWxsc3BhY2luZz0wIGJnY29sb3I9d2hpdGUgd2lkdGg9JzEwMCUnPg0KICAgICAgICAg
ICAgICAgICAgICAgICAgICAgIDx0cj48dGQgYWxpZ249J2NlbnRlcic+PGltZyBzcmM9J2h0dHA6
Ly9pbWFnZXMucGVyc29uYWxkYi5uZXQvcmVjb21tX3RvcC5naWYnIHdpZHRoPTQ5OCBoZWlnaHQ9
MjkgYm9yZGVyPTA+PC90ZD48L3RyPjwvdGFibGU+PC90ZD48L3RyPg0KICAgICAgICAgICAgICAg
IDx0ciB2YWxpZ249J3RvcCc+DQogICAgICAgICAgICAgICAgICAgIDx0ZCBhbGlnbj0nbGVmdCcg
d2lkdGg9ODAlIHN0eWxlPXBhZGRpbmctbGVmdDoyMD48YnI+DQogICAgICAgICAgICAgICAgICAg
IDxmb250IGNvbG9yPScjMDA4MDgwJz48Yj5Uby4mbmJzcDtidWctY29tbW9uY3BwILTUsrI8L2I+
PGJyPg0KICAgICAgICAgICAgICAgICAgICBQZXJzb25hbERCLm5ldCDIuL/4wLi3ziDDyrTrud7A
uLzMvcC0z7TZLiBbyKsgILq4XTxicj4NCiAgICAgICAgICAgICAgICAgICAgPGRpdiBhbGlnbj0n
cmlnaHQnPjxiPkZyb20uJm5ic3A7wKWw/LiuwNogKCBtYWlsbWFzdGVyICk8L2I+Jm5ic3A7Jm5i
c3A7PC9kaXY+PC9mb250PjxociBzaXplPScxJyBjb2xvcj0nIzgyODI4Mic+PC90ZD4NCiAgICAg
ICAgICAgICAgICAgICAgPHRkIGFsaWduPSdyaWdodCcgdmFsaWduPXRvcCB3aWR0aD0nMjAlJz48
aW1nIHNyYz0naHR0cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC9pbnRyby9wb3N0LmpwZycgYm9y
ZGVyPTA+PC90ZD48L3RyPg0KICAgICAgICAgICAgICAgIDx0ciB2YWxpZ249J3RvcCc+DQogICAg
ICAgICAgICAgICAgICAgIDx0ZCB2YWxpZ249J3RvcCcgYWxpZ249J2xlZnQnIGNvbHNwYW49JzIn
Pg0KICAgICAgICAgICAgICAgICAgICA8Zm9udCBjb2xvcj0nbmF2eSc+PHVsPr7Is+fHz7y8v+Qu
ILi4s6ogusuw1CC1x77uILndsKm9wLTPtNkuPGJyPjxicj66uyC758DMxq60wiDIv8CywPvAuLfO
IMDavcXAxyDB9r3EsPogwaS6uCwgwNq34bXpwLsgsPy4rsfPuOcgwMy3r8fRIMDat+G4piDEo7G4
temw+iCw+MCvx8+wxbOqIMioxuTAzMH2v6EgsNS9wywgtse0wiDB9r3Ew6Kw7b+hvK0gxse4xcfS
ILz2IMDWtMIgu/W3zr/uIL3DvbrF28DUtM+02S48YnI+PGJyPrHNx8+ysrytIL+pt68gwNq34bOq
IMH2vcTAuyCwrrDtILDovcO02bjpIMD6yPG/zSDH1LKyIMfPvcOx4rimILnZtvi0z7TZLjxicj6x
zcfPsrK8rSDGr8GkutC+38DHIMD8ua6wobOqILjFtM++xr3DtvO46SDA+sjxv80gx9SysiDHz73D
seK4piC52bb4tM+02S48YnI+sc3Hz7KyvK0gv6m3ryDBpLq4uKYgw6Ow7SCw6L3FtNm46SDA+sjx
v80gx9SysiDHz73DseK4piC52bb4tM+02S48YnI+sc3Hz7KyvK0gv6m3ryDA2rfhtem4piDEo7G4
s6ogtb+34bXpsPogsPjAr8fPsO0gvc3AuL3DuOkgwPrI8b/NIMfUsrIgx8+9w7HiuKYgudm2+LTP
tNkuPGJyPrHNx8+ysrytILHNx8+/zSCxzcfPwMcgxKO/7LXpuLjAxyC/wrbzwM4guPDA08C7ILCu
sO0gvc3AuL3DtNm46SDA+sjxv80gx9SysiDHz73DseK4piC52bb4tM+02S48YnI+sc3Hz7KyvK0g
sc3Hz8DHIMH2vcTAuLfOILjFv/kgwM/BpMfRILz2wNTAuyC+8rDtIL3NwLi9w7jpIMD6yPG/zSDH
1LKyIMfPvcOx4rimILnZtvi0z7TZLjxicj6xzcfPsrK8rSDIqMbkwMzB9rimILCusO0gsOi9w7DF
s6ogyKjG5MDMwfa4piC4uLXlvccgv7nBpMDMuOkgwPrI8b/NIMfUsrIgx8+9w7HiuKYgudm2+LTP
tNkuPGJyPrHNx8+ysrytIMi4u+e/zSDB/SwgUEO55rXuIL+pt68gwOW80r+hvK0gxMTHu8XNuKYg
u+e/68fPvcW02bjpIMD6yPG/zSDH1LKyIMfPvcOx4rimILnZtvi0z7TZLjxicj48YnI+wKfAxyDB
9r3EsPy4riDAzL/cv6G1tSC4ucC6ILytuvG9urChIMGmsPi1x7jnILytuvG9urTCILDovNMgyK60
67XHsO0gwNa9wLTPtNkuPGJyPjxicj6wocDUwLoguau34cDUtM+02S48YnI+PGJyPsbtwfawoSCx
zcfPv80gx9SysiC79bfOv+4gwfa9xCzBpLq4yLC1v8C7IMfSILz2IMDWtMIgwNvAuiDAzr+swMwg
tckgvPYgwNax5iDB+L3JwLi3ziC52bbzuOcsIMfjtvS++MDMILq7ILjewM/AuyC6uLO9taUgtOvH
z7+pIMHLvNu9urexILi2wL3AuyCx3cfSILz2IL74vcC0z7TZLjxicj6+1cC4t84gw9+wobXHtMIg
vK268b26v80gte63z7XHtMIgv6m3ryC/7Lz2x9EgwNq34bXpv6EgsPzH0SDBpLq4uKYgwaaw+MfY
ILXluLEgv7nBpMDUtM+02bi4ILi4wM8gwPrI8SC758DMxq63zrrOxc0guN7Az8C7ILnewfYgvsqx
4rimIL/4x8+9w7TCILDmv+wgvsa3ocDHILz2vcWwxbrOuKYgu+e/68fPvccgvPYgwNa9wLTPtNku
PGJyPjxicj6wqLvnx9W0z7TZLjwvdWw+PC9mb250PjwvdGQ+PC90cj4NCiAgICAgICAgICAgICAg
ICA8dHIgdmFsaWduPSd0b3AnPg0KICAgICAgICAgICAgICAgICAgICA8dGQgdmFsaWduPSd0b3An
IGFsaWduPSdjZW50ZXInIGNvbHNwYW49JzInPg0KICAgICAgICAgICAgICAgICAgICA8YSBocmVm
PSdodHRwOi8vd3d3LlBlcnNvbmFsREIubmV0JyB0YXJnZXQ9J19ibGFuayc+PGltZyBib3JkZXI9
MCBzcmM9J2h0dHA6Ly9pbWFnZXMucGVyc29uYWxkYi5uZXQvdG4xNDUuZ2lmJz48L2E+PC90ZD48
L3RyPg0KICAgICAgICAgICAgICAgIDx0cj48dGQgY29sc3Bhbj0yIGhlaWdodD0xMD48L3RkPjwv
dHI+DQogICAgICAgICAgICAgICAgPHRyPjx0ZCBjb2xzcGFuPTIgYmdjb2xvcj0jODI4MjgyIGhl
aWdodD0yIHdpZHRoPTEwMCU+PC90ZD48L3RyPjwvdGFibGU+PC90ZD48L3RyPg0KCTx0cj48dGQg
aGVpZ2h0PTUwPjwvdGQ+PC90cj4NCgk8dHI+PHRkPjxpbWcgc3JjPWh0dHA6Ly9pbWFnZXMucGVy
c29uYWxkYi5uZXQvYXJyb3cxMi5naWYgYWxpZ249YWJzbWlkZGxlPiBQZXJzb25hbERCtMI/PC90
ZD48L3RyPg0KCTx0cj48dGQ+PGltZyBzcmM9aHR0cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC9k
b3RsaW5lNS5naWY+PC90ZD48L3RyPg0KCTx0cj48dGQgaGVpZ2h0PTEwPjwvdGQ+PC90cj4NCgk8
dHI+PHRkIGFsaWduPWNlbnRlcj48aW1nIHNyYz1odHRwOi8vaW1hZ2VzLnBlcnNvbmFsZGIubmV0
L2ludHJvL3NlcnZpY2VfaW50cm8yLmdpZj48L3RkPjwvdHI+DQoJPHRyPjx0ZCBoZWlnaHQ9MjA+
PC90ZD48L3RyPg0KCTx0cj48dGQgc3R5bGU9cGFkZGluZy1sZWZ0OjIwPg0KCQkJPHRhYmxlIGJv
cmRlcj0wIGNlbGxwYWRkaW5nPTAgY2VsbHNwYWNpbmc9MCB3aWR0aD0xMDAlPg0KCQkJICA8dHI+
PHRkIHdpZHRoPTE4MD48aW1nIHNyYz0iaHR0cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC9zaXRl
bWFwMi5naWYiIHdpZHRoPTE2MCBoZWlnaHQ9NDAgYm9yZGVyPTAgYWx0PSKws8DOtfC68SI+PC90
ZD4NCgkJCQkgIDx0ZD4NCgkJCQkJLSDA2rfhwMcguriw/CwgsPjArywguMW4xbimIMCnx9EgsLPA
zkRCIMGmsPg8YnI+DQoJCQkJCS0gsLPAzsDat+G9xywgsLPAzr7ZufwsILCzwM66z7i2xam3ziCx
uLy6PGJyPg0KCQkJCQktILq4sPy/6yzIqMbkwMzB9iCw1L3DLMDat+Gw+MCvLMH2vcTDorDtv6G8
rcDHIMbHuMW/68C4t84gyLC/6zwvdGQ+PC90cj4NCgkJCTwvdGFibGU+DQoJCTwvdGQ+PC90cj4N
Cgk8dHI+PHRkIGhlaWdodD0xMD48L3RkPjwvdHI+DQoJPHRyPjx0ZCBzdHlsZT1wYWRkaW5nLWxl
ZnQ6MjA+DQoJCQk8dGFibGUgYm9yZGVyPTAgY2VsbHBhZGRpbmc9MCBjZWxsc3BhY2luZz0wIHdp
ZHRoPTEwMCU+DQoJCQkgIDx0cj48dGQgd2lkdGg9MTgwPjxpbWcgc3JjPSJodHRwOi8vaW1hZ2Vz
LnBlcnNvbmFsZGIubmV0L3NpdGVtYXA0LmdpZiIgd2lkdGg9MTYwIGhlaWdodD00MCBib3JkZXI9
MCBhbHQ9IrCzwM618LrxIj48L3RkPg0KCQkJCSAgPHRkPg0KCQkJCQktIL26xMnB2bevLCDAz7Hi
wOUsILjeuPDA5SwgVG8gRG8gTGlzdCwgsLPAzsHWvNK3zy4uLjxicj4NCgkJCQkJLSCws8DOwaS6
uLD8uK6/oSDHyr/kx9EguPC15yCws8DOvK268b26IMGmsPg8YnI+DQoJCQkJCS0gxu24rsfPsO0g
sK23wsfRILTrv+u3riDGxMDPwPy82yC8rbrxvbo8YnI+DQoJCQkJCS0guPC15yC8rbrxvbrA2rfh
tMIgtNm+58fPsNQgyLC/67XKPC90ZD48L3RyPg0KCQkJPC90YWJsZT4NCgkJPC90ZD48L3RyPg0K
CTx0cj48dGQgaGVpZ2h0PTEwPjwvdGQ+PC90cj4NCgk8dHI+PHRkIHN0eWxlPXBhZGRpbmctbGVm
dDoyMD4NCgkJCTx0YWJsZSBib3JkZXI9MCBjZWxscGFkZGluZz0wIGNlbGxzcGFjaW5nPTAgd2lk
dGg9MTAwJT4NCgkJCSAgPHRyPjx0ZCB3aWR0aD0xODA+PGltZyBzcmM9Imh0dHA6Ly9pbWFnZXMu
cGVyc29uYWxkYi5uZXQvc2l0ZW1hcDEuZ2lmIiB3aWR0aD0xNjAgaGVpZ2h0PTQwIGJvcmRlcj0w
IGFsdD0isLPAzrXwuvEiPjwvdGQ+DQoJCQkJICA8dGQ+DQoJCQkJCS0gvsa/9LfowMcgseK0ycC7
ILjwtc4gwKXAuLfOPGJyPg0KCQkJCQktILCtt8LHz7DtIMbtuK7H0SDB+MGkx9EgwKW43sDPPGJy
Pg0KCQkJCQktILXwt7rF5LiusPy4riy89r3FsMW6zsG2sMcsus7A58HfwMC05CxQT1DB9r/4te4g
sK23wsfRILHitMk8L3RkPjwvdHI+DQoJCQk8L3RhYmxlPg0KCQk8L3RkPjwvdHI+DQoJPHRyPjx0
ZCBoZWlnaHQ9MTA+PC90ZD48L3RyPg0KCTx0cj48dGQgc3R5bGU9cGFkZGluZy1sZWZ0OjIwPg0K
CQkJPHRhYmxlIGJvcmRlcj0wIGNlbGxwYWRkaW5nPTAgY2VsbHNwYWNpbmc9MCB3aWR0aD0xMDAl
Pg0KCQkJICA8dHI+PHRkIHdpZHRoPTE4MD48aW1nIHNyYz0iaHR0cDovL2ltYWdlcy5wZXJzb25h
bGRiLm5ldC9zaXRlbWFwMy5naWYiIHdpZHRoPTE2MCBoZWlnaHQ9NDAgYm9yZGVyPTAgYWx0PSKw
s8DOtfC68SI+PC90ZD4NCgkJCQkgIDx0ZD4NCgkJCQkJLSC48LXnIMi4v/hEQsDHILrQt/m6sCC4
8MC9PGJyPg0KCQkJCQktIMD8ua6wocTas8osIFEmQSC17sDHILTZvufH0SDB9r3EvcC15rnmuf08
YnI+DQoJCQkJCS0gyLi/+CCws8DOwfa9xCwgwNq34cDHIMbHuMWwoSCwobTJPGJyPg0KCQkJCQkt
ILCiIMi4v/i16cDHIMD8ua6w1L3Dxse48MC9wLi3ziC02b7nx9EgwNq34SC9wLXmsKG0yTwvdGQ+
PC90cj4NCgkJCTwvdGFibGU+DQoJCTwvdGQ+PC90cj4NCgk8dHI+PHRkIGhlaWdodD0xMD48L3Rk
PjwvdHI+DQoJPHRyPjx0ZCBzdHlsZT1wYWRkaW5nLWxlZnQ6MjA+DQoJCQk8dGFibGUgYm9yZGVy
PTAgY2VsbHBhZGRpbmc9MCBjZWxsc3BhY2luZz0wIHdpZHRoPTEwMCU+DQoJCQkgIDx0cj48dGQg
d2lkdGg9MTgwPjxpbWcgc3JjPSJodHRwOi8vaW1hZ2VzLnBlcnNvbmFsZGIubmV0L3NpdGVtYXA1
LmdpZiIgd2lkdGg9MTYwIGhlaWdodD00MCBib3JkZXI9MCBhbHQ9IrCzwM618LrxIj48L3RkPg0K
CQkJCSAgPHRkPg0KCQkJCQktIMioxuTAzMH2ILi2uf2757fOILCjtNzH0SCxuLy6ILChtMk8YnI+
DQoJCQkJCS0gxsTAz7jFtM/A+rfOIMClu/O/obytILvowaYsIL73L7TZv+63zrXlLCC89sGkILCh
tMk8YnI+DQoJCQkJCS0gsLPAzkRCwNq34cDHIMDatb++97WlwMzGriCx4rTJwLi3ziCw/LiuILCj
xu08YnI+DQoJCQkJCS0gsPjB9rvnx9csILDUvcPGxywguea47bfPLCDEq7/uxc217iC02b7nx9Eg
us6wobytuvG9ujwvdGQ+PC90cj4NCgkJCTwvdGFibGU+DQoJCTwvdGQ+PC90cj4NCgk8dHI+PHRk
IGhlaWdodD0xMD48L3RkPjwvdHI+DQoJPHRyPjx0ZCBzdHlsZT1wYWRkaW5nLWxlZnQ6MjA+DQoJ
CQk8dGFibGUgYm9yZGVyPTAgY2VsbHBhZGRpbmc9MCBjZWxsc3BhY2luZz0wIHdpZHRoPTEwMCU+
DQoJCQkgIDx0cj48dGQgd2lkdGg9MTgwPjxpbWcgc3JjPSJodHRwOi8vaW1hZ2VzLnBlcnNvbmFs
ZGIubmV0L3NpdGVtYXA2LmdpZiIgd2lkdGg9MTYwIGhlaWdodD00MCBib3JkZXI9MCBhbHQ9IrCz
wM618LrxIj48L3RkPg0KCQkJCSAgPHRkPg0KCQkJCS0gxvO84rzSuPDA07D6ILD4sLO80rjwwNPA
uLfOILG4utA8YnI+DQoJCQkJLSCws8DORELAxyCw+MCvILChtMk8YnI+DQoJCQkJLSCw+MH2u+fH
1ywgsNS9w8bHLCDA2rfhvccsIMi4v/jB1rzSt8+17iC02b7nx9EgvK268b26IMGmsPg8L3RkPjwv
dHI+DQoJCQk8L3RhYmxlPg0KCQk8L3RkPjwvdHI+DQoJPHRyPjx0ZCBoZWlnaHQ9NDA+PC90ZD48
L3RyPg0KCTx0cj48dGQ+PGltZyBzcmM9aHR0cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC9hcnJv
dzEyLmdpZiBhbGlnbj1hYnNtaWRkbGU+IL7utrK60L+hsNQgx8q/5MfSse6/5D88L3RkPjwvdHI+
DQoJPHRyPjx0ZD48aW1nIHNyYz1odHRwOi8vaW1hZ2VzLnBlcnNvbmFsZGIubmV0L2RvdGxpbmU1
LmdpZj48L3RkPjwvdHI+DQoJPHRyPjx0ZCBoZWlnaHQ9MTA+PC90ZD48L3RyPg0KCTx0cj48dGQg
c3R5bGU9cGFkZGluZy1sZWZ0OjIwO2xpbmUtaGVpZ2h0OjE4cHg+DQoJCQk8bGk+wf0sIMfQsbMs
IMi4u+csIFBDuea17iC/qbevIMDlvNK/obytIFBDuKYgu+e/68fPtMIgutANCgkJCTxsaT6+7ray
ILrQvt/AxyDA2rfhuKYguPDAuL3DsMWzqiC4ucDMILq4wK/Hz7DtILDovcUgutANCgkJCTxsaT7H
0SC60L7fwMcgwPy5rrChwMywxbOqILjFtM++xsDMvcUgutANCgkJCTxsaT7B37/kx9EgwNq34bim
ILq4sPzH2L7fIMfPtMIgutANCgkJCTxsaT7A2r3FwMcgwfa9xMDMs6ogwaS6uCwgwNq34bfOILjF
v/kgvPbAzcC7IL/DuK6w7SC9zcC4vcUgutANCgkJCTxsaT7Hyr/kx9Egwfa9xMDMs6ogwaS6uLim
IMOjvsYgwKW8rcfOwLsgwNrB1iDHz73DtMIgutANCgkJCTxsaT7Gr8Gkx9EgutC+37+hILTrx8+/
qSDA/LmusKHAxyC1tb/ywMwgx8q/5MfPvcUgutANCgkJCTxsaT7Eo7G4s6ogtb+34bXpsPogwNq3
4bimILGzyK8ssPjAr8fSIMfKv+SwoSDA1sC4vcUgutANCgkJCTxsaT7IqMbkwMzB9rimILCusO0g
wNawxbOqILi4tem3wbDtIMfPvcO0wiC60A0KCQkJPGxpPsioxuTAzMH2uKYgsK6w7SDA1sH2uLgg
sPy4rsfPtMIgtaW/oSC+7rfBv/LAuyC0wLOisMWzqiCxzcL6wLi9xSC60CANCgkJCTxsaT7Eo7G4
LCC1v8OiLCC1v7fhte6w+iC/7LiuuLjAxyC48MDTwLsguLi16bDtIL3NwLi9xSC60LXpDQoJCQk8
bGk+vu62siDB1sGmv6EgtOvHz7+pIL+pt68gu+e297XpsPrAxyC48MDTwMwgx8q/5MfPvcUgutC1
6Q0KCQkJPGxpPsDPseIsuN648MDlLL26xMnB2bevte4gv6m3ryCws8DOvK268b26uKYgwMy/68fP
sO0gvc3AuL3FILrQDQoJCQk8bGk+xu24rsfPsO0gsK23wsfRIMD8wNq/7MbtwMwgx8q/5MfPvcUg
utANCgkJCTxsaT6wocG3LMSjsbgstb+34b/NwMcgu+fB+MC7IMD8wNq+2bn8wLi3ziDBpsDbx8+w
7SC9zcC4vcUgutANCgkJCTxsaT65q775uri02bW1IMO8sOjA+8DMuOcgyL+w+sD7wM4gwfa9xLDm
wO+3wsC7ILCuw9+w7SC9zcC4vcUgutA8YnI+PGJyPg0KCQk8L3RkPjwvdHI+DQoJPHRyPjx0ZCBo
ZWlnaHQ9MTA+PC90ZD48L3RyPg0KCTx0cj48dGQgYWxpZ249cmlnaHQ+wMy3sSC60LXpwLogvu68
rSCwocDUx8+8vL/kLiC79bfOv+4gvK268b26uKYgtMCzor3HILz2IMDWvcC0z7TZLgk8L3RkPjwv
dHI+DQoJPHRyPjx0ZCBoZWlnaHQ9NDA+PC90ZD48L3RyPg0KCTx0cj48dGQ+PGltZyBzcmM9aHR0
cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC9hcnJvdzEyLmdpZiBhbGlnbj1hYnNtaWRkbGU+ILCh
wNS68b/rILnXIMDMv+u34bTCPzwvdGQ+PC90cj4NCgk8dHI+PHRkPjxpbWcgc3JjPWh0dHA6Ly9p
bWFnZXMucGVyc29uYWxkYi5uZXQvZG90bGluZTUuZ2lmPjwvdGQ+PC90cj4NCgk8dHI+PHRkIGhl
aWdodD0xMD48L3RkPjwvdHI+DQoJPHRyPjx0ZCBzdHlsZT1wYWRkaW5nLWxlZnQ6MjA7bGluZS1o
ZWlnaHQ6MThweD4NCgkJCbmwt9AgsKHA1LD6IMDMv+u34bTCILmrt+HA1LTPtNkuPGJyPrTcwfYg
sKHA1MfPvcOx4ri4IMfPuOkgwKfAxyC48LXnILytuvG9urimIMDMv+vHz73HILz2IMDWvcC0z7TZ
Ljxicj4NCgkJCcfPwfa4uCC4ucC6IL/rt66w+iDGr7qwx9Egx/3Fw8C7IL/4x8+9w7TCILrQtenA
uyDAp8fPv6kgx8G4rrnMvvbIuL/4waa1tbimIL/uv7XHz7DtIMDWvcC0z7TZLjxicj4NCgkJCcfB
uK65zL72yLi/+MC4t84gsKHA1MfPvcO46SDA+rfFx9EgsKGw3cC4t84gw+a60MfRIL/rt66w+iDH
1LKyIMH2vcTDorDtv6G8rcDHILjFuMWzqiDEwcXZw/exuMDUvcMgxq+6sMfRIMf9xcPAuyC15biz
tM+02S48YnI+DQoJCQnHwbiuucy+9si4v/jAuLfOILChwNQuLi4gwfa60rXHtMIguvG/67q4tNkg
uLnAuiDAzMDNwMwgyLi/+L+pt6+60LKyILW5vsawqbTPtNkuPGJyPsH2sd0gsKHA1MfPvLy/5A0K
CQk8L3RkPjwvdHI+DQoJPHRyPjx0ZCBoZWlnaHQ9MjA+PC90ZD48L3RyPg0KCTx0cj48dGQgYWxp
Z249Y2VudGVyPjxhIGhyZWY9Imh0dHA6Ly93d3cuUGVyc29uYWxEQi5uZXQiIHRhcmdldD0iX2Js
YW5rIj48aW1nIGJvcmRlcj0wIHNyYz0iaHR0cDovL2ltYWdlcy5wZXJzb25hbGRiLm5ldC90bjE0
NS5naWYiPjwvYT48L3RkPjwvdHI+DQoJPHRyPjx0ZD4NCiAgICAgICAgICA8VEFCTEUgYm9yZGVy
PTAgY2VsbFBhZGRpbmc9MCBjZWxsU3BhY2luZz0wIHdpZHRoPTYwMD4NCiAgICAgICAgICAgIDxU
Qk9EWT4gDQogICAgICAgICAgICA8VFI+IA0KICAgICAgICAgICAgICA8VEQgYWxpZ249bWlkZGxl
IGhlaWdodD00NSB2QWxpZ249Ym90dG9tPg0KICAgICAgICAgICAgICAgIDxTUEFOIGNsYXNzPXZl
cmRhbmE+Q29weXJpZ2h0IKjPMjAwMSBQZXJzb25hbERCLm5ldCBBbGwgcmlnaHRzIHJlc2VydmVk
LiBXaXRoIFF1ZXN0aW9ucywgcGxlYXNlIDxBIGhyZWY9Imh0dHA6Ly93d3cuUGVyc29uYWxEQi5u
ZXQvZGVmYXVsdC5hc3A/ZGlyZWN0PWFzay5odG0iIHRhcmdldD0iX2JsYW5rIj5FLW1haWwgdXM8
L0E+IHwgDQogICAgICAgICAgICAgICAgPGEgaHJlZj0naHR0cDovL3d3dy5wZXJzb25hbGRiLm5l
dC9saWIvcmVqZWN0X21haWwuYXNwP2FkZHI9YnVnLWNvbW1vbmNwcEBnbnUub3JnJz689r3FsMW6
zjwvYT4NCgkJCQk8L1NQQU4+DQoJCQkgIDwvVEQ+DQogICAgICAgICAgICA8L1RSPg0KICAgICAg
ICAgICAgPC9UQk9EWT4gDQogICAgICAgICAgPC9UQUJMRT4NCgkJPC90ZD48L3RyPgkNCjwvdGFi
bGU+DQo8L2Rpdj4NCjwvYm9keT4NCjwvaHRtbD4NCg==

------=_NextPart_000_98F1_01C1C0C9.F8C69D50--



From fedemp@arrok.com Thu Feb 28 13:36:18 2002
Received: from 80-24-225-168.uc.nombres.ttd.es ([80.24.225.168] helo=tirante.arrok.com)
	by fencepost.gnu.org with smtp (Exim 3.33 #1 (Debian))
	id 16gVPc-0003yf-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 13:36:17 -0500
Received: from marta.arrok.com ([10.0.0.120])
	by tirante.arrok.com with esmtp (Exim 3.12 #1 (Debian))
	id 16gVQo-0003YZ-00; Thu, 28 Feb 2002 19:37:30 +0100
Received: from fedemp by marta.arrok.com with local (Exim 3.34 #1 (Debian))
	id 16gVPx-0006fr-00; Thu, 28 Feb 2002 19:36:37 +0100
Date: Thu, 28 Feb 2002 19:36:32 +0100
From: Federico Montesino Pouzols <fedemp@arrok.com>
To: bug-commoncpp@gnu.org
Cc: Hieu Thao <hieuthao@vdi-tech.com>
Subject: Re: Linking CommonC++-1.9.5 into my project under Redhat 7.2
Message-ID: <20020228183632.GD22185@marta>
Mail-Followup-To: bug-commoncpp@gnu.org, Hieu Thao <hieuthao@vdi-tech.com>
References: <005701c1c034$e022bd50$636310ac@thaoxp>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <005701c1c034$e022bd50$636310ac@thaoxp>
User-Agent: Mutt/1.3.27i
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/>

On Thu, Feb 28, 2002 at 03:49:41PM +0700, Hieu Thao wrote:
> Hi,

	Hi,

> LDFLAGS = @LDFLAGS@ $(LT_VERSION) -release $(LT_RELEASE)
> ccxxincludedir=$(includedir)/cc++
> ...

	If you are a beginner, you should not care about Makefile.am
yet. First, compile and install the library (with the usual GNU
package building system):

	- enter the directory containing cc++ sources
	- type ./configure
	- type make
	- type make install (with the necessary permission to install programs on your system)

	Once installed, there is a script called `ccgnu-config' that
provides the flags and libraries you need to specify to g++. Try
typing `ccgnu-config --help', `ccgnu-config --flags', etc.

	Also, I would recommend you to search trough this mailing list
archives and the public forums at sf.net/projects/cplusplus, so that
you can get more familiar with cc++.

> 
> What it's mean?
> If I wanted to use KDevelop, I would set how to parameter option project.
> Thanks for helping me.

	Bye.


From Haranath.Varanasi@scada.cmcltd.com Thu Feb 28 23:12:48 2002
Received: from delysid.gnu.org ([158.121.106.20])
	by fencepost.gnu.org with esmtp (Exim 3.33 #1 (Debian))
	id 16gePY-0002uC-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 23:12:48 -0500
Received: from [196.12.38.85] (helo=scada.cmcltd.com)
	by delysid.gnu.org with esmtp (Exim 3.34 #2)
	id 16gePV-0007Nu-00
	for <bug-commoncpp@gnu.org>; Thu, 28 Feb 2002 23:12:46 -0500
Received: from localhost (haranath@localhost)
	by scada.cmcltd.com (8.11.2/8.8.7) with ESMTP id g21437J01608
	for <bug-commoncpp@gnu.org>; Fri, 1 Mar 2002 09:33:44 +0530
Date: Fri, 1 Mar 2002 09:33:07 +0530 (IST)
From: <Haranath.Varanasi@scada.cmcltd.com>
To: <bug-commoncpp@gnu.org>
Subject: digital unix 
In-Reply-To: <E16g7Tp-00045Q-00@fencepost.gnu.org>
Message-ID: <Pine.LNX.4.33.0203010930260.1274-100000@scada.cmcltd.com>
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/>

hi
has any body using commmon cpp on Tru64 unix .
what are the minimum requirements of a system to use common cpp.
regards
haranath




