forked from enlightenment/efl
elm_code_text: Return empty string on 0 length.
Throughout elm_code we rely on this function returning a valid string (unless the line object isn't set/is NULL).
This commit is contained in:
parent
f2b88560a0
commit
207da69c97
|
@ -19,6 +19,9 @@ elm_code_line_text_get(Elm_Code_Line *line, unsigned int *length)
|
|||
if (length)
|
||||
*length = line->length;
|
||||
|
||||
if (!line->length)
|
||||
return "";
|
||||
|
||||
if (line->modified)
|
||||
return line->modified;
|
||||
return line->content;
|
||||
|
|
Loading…
Reference in New Issue