aboutsummaryrefslogtreecommitdiff
path: root/src/fstring.h
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2007-12-04 21:21:10 +0000
committerMike Buland <eichlan@xagasoft.com>2007-12-04 21:21:10 +0000
commitcdddb1e4bc3230dc8c0bc522c613e709d0afbdff (patch)
treee91ed03671589edbec1daf49c924987f56330782 /src/fstring.h
parent4793dc0defc369c65671cc2b9f00ac4152015f4c (diff)
downloadlibbu++-cdddb1e4bc3230dc8c0bc522c613e709d0afbdff.tar.gz
libbu++-cdddb1e4bc3230dc8c0bc522c613e709d0afbdff.tar.bz2
libbu++-cdddb1e4bc3230dc8c0bc522c613e709d0afbdff.tar.xz
libbu++-cdddb1e4bc3230dc8c0bc522c613e709d0afbdff.zip
Minor update to Bu::FString, it now always returns a valid C style string when
asked for the string, no null pointers anymore.
Diffstat (limited to '')
-rw-r--r--src/fstring.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fstring.h b/src/fstring.h
index 82e8b34..155d6af 100644
--- a/src/fstring.h
+++ b/src/fstring.h
@@ -353,7 +353,7 @@ namespace Bu
353 chr *getStr() 353 chr *getStr()
354 { 354 {
355 if( pFirst == NULL ) 355 if( pFirst == NULL )
356 return NULL; 356 return (chr *)"";
357 357
358 flatten(); 358 flatten();
359 pFirst->pData[nLength] = (chr)0; 359 pFirst->pData[nLength] = (chr)0;
@@ -367,7 +367,7 @@ namespace Bu
367 const chr *getStr() const 367 const chr *getStr() const
368 { 368 {
369 if( pFirst == NULL ) 369 if( pFirst == NULL )
370 return NULL; 370 return (chr *)"";
371 371
372 flatten(); 372 flatten();
373 pFirst->pData[nLength] = (chr)0; 373 pFirst->pData[nLength] = (chr)0;