diff options
author | Mike Buland <eichlan@xagasoft.com> | 2007-12-04 21:21:10 +0000 |
---|---|---|
committer | Mike Buland <eichlan@xagasoft.com> | 2007-12-04 21:21:10 +0000 |
commit | cdddb1e4bc3230dc8c0bc522c613e709d0afbdff (patch) | |
tree | e91ed03671589edbec1daf49c924987f56330782 /src/fstring.h | |
parent | 4793dc0defc369c65671cc2b9f00ac4152015f4c (diff) | |
download | libbu++-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.h | 4 |
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; |