Elm_Entry: Removed empty line and added error message

Summary:
Resolved FIXME in utf8_markup_save by adding error messages
for fopen and fputs command

Signed-off-by: kabeer khan <kabeer.khan@samsung.com>

Reviewers: devilhorns, seoz

Reviewed By: seoz

Differential Revision: https://phab.enlightenment.org/D1888
This commit is contained in:
kabeer khan 2015-01-30 08:02:21 +09:00 committed by Daniel Juyung Seo
parent c9c5463c7e
commit d87b5c0e41
1 changed files with 3 additions and 3 deletions

View File

@ -207,18 +207,18 @@ _utf8_markup_save(const char *file,
if ((!text) || (!text[0]))
{
ecore_file_unlink(file);
return;
}
f = fopen(file, "wb");
if (!f)
{
// FIXME: report a write error
ERR("Failed to open %s for writing", file);
return;
}
fputs(text, f); // FIXME: catch error
if (fputs(text, f) == EOF)
ERR("Failed to write text to file %s", file);
fclose(f);
}