Skip to content

Commit

Permalink
more small changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Dejan Jovanovic committed Mar 11, 2016
1 parent f28a181 commit 79cec52
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/utils/string.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,11 @@ const char* string::end() const {


size_t string::size() const {
return strlen(d_data);
if (d_data) {
return strlen(d_data);
} else {
return 0;
}
}

char string::operator[] (size_t i) const {
Expand Down

0 comments on commit 79cec52

Please sign in to comment.