string clear check

master
Daniel Kolesa 2015-08-05 21:58:06 +01:00
parent 4f23017594
commit 8ba91c12fe
1 changed files with 1 additions and 0 deletions

View File

@ -331,6 +331,7 @@ public:
} }
void clear() { void clear() {
if (!p_len) return;
p_len = 0; p_len = 0;
*p_buf.first() = '\0'; *p_buf.first() = '\0';
} }