<br><font size=2 face="sans-serif">I tend to agree with Alex's point of view on this... If the function is supposed to return a string, then returning NULL is probably not a great idea.</font>
<br>
<br><font size=2 face="sans-serif">I would tend to say that I've taken the approach in our software components that in general, if something returns a string, it's safer to return an empty string than a NULL pointer. I know it's a personal preference, but when other people use libs that I've designed/developed, the empty string implementation SUBSTANTIALLY reduces core dumps :-))</font>
<br>
<br><font size=2 face="sans-serif">That's my $0.02 worth</font>
<br>
<br><font size=2 face="sans-serif">Renny Koshy<br>
President & CEO<br>
<br>
--------------------------------------------<br>
RUBIX Information Technologies, Inc.<br>
www.rubixinfotech.com</font>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td>
<td><font size=1 face="sans-serif"><b>Alex Tingle <alex.tingle@bronermetals.com></b></font>
<br><font size=1 face="sans-serif">Sent by: omniorb-list-bounces@omniorb-support.com</font>
<p><font size=1 face="sans-serif">09/28/2004 07:31 AM</font>
<br>
<td><font size=1 face="Arial"> </font>
<br><font size=1 face="sans-serif"> To: 'omniorb-list@omniorb-support.com' list <omniorb-list@omniorb-support.com></font>
<br><font size=1 face="sans-serif"> cc: </font>
<br><font size=1 face="sans-serif"> Subject: Re: [omniORB] SystemException::NP_minorString() returns 0</font></table>
<br>
<br>
<br><font size=2 face="Courier New"><br>
>> cout<<ex->NP_minorString()<<endl;<br>
><br>
> In all the iostream implementations I know, the latter will just print<br>
> (null) or something similar, so it's not especially harmful.<br>
<br>
Well, it causes a segmentation fault on my Linux box with gcc 2.95. <br>
I'll stick with my wrapper macro.<br>
<br>
-Alex<br>
<br>
--<br>
Dammit Jim, I'm a programmer... not a mind reader!<br>
<br>
<br>
_______________________________________________<br>
omniORB-list mailing list<br>
omniORB-list@omniorb-support.com<br>
http://www.omniorb-support.com/mailman/listinfo/omniorb-list<br>
</font>
<br>
<br>