rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=4a7e3de3d860e4767861ccd1c35f5f6648badda6
commit 4a7e3de3d860e4767861ccd1c35f5f6648badda6 Author: Vitalii Vorobiov <[email protected]> Date: Tue Mar 28 12:03:13 2017 +0300 main_window: use correct portable function to read from file getfile is GNU Linux only, better use portable stuff @fix --- src/bin/ui/main_window.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/bin/ui/main_window.c b/src/bin/ui/main_window.c index 0ec3be4..603bc9d 100644 --- a/src/bin/ui/main_window.c +++ b/src/bin/ui/main_window.c @@ -249,9 +249,6 @@ _about_window_content_get(void *data, Evas_Object *popup __UNUSED__, Evas_Object Eina_Strbuf *authors_file_path = NULL; Eina_Strbuf *authors = NULL; FILE *authors_file = NULL; - char *line = NULL; - size_t len = 0; - ssize_t read = 0; authors_file_path = eina_strbuf_new(); eina_strbuf_prepend_printf(authors_file_path, "%s/AUTHORS", elm_app_data_dir_get()); @@ -269,10 +266,9 @@ _about_window_content_get(void *data, Evas_Object *popup __UNUSED__, Evas_Object "<br>" "<align=center><b>Authors:</b><br>"); - while ((read = getline(&line, &len, authors_file)) != -1) - { - eina_strbuf_append_printf(authors, "%s<br>", line); - } + char line [BUFF_MAX]; + while (fgets(line, sizeof(line), authors_file ) != NULL) + eina_strbuf_append_printf(authors, "%s<br>", line); eina_strbuf_append_printf(authors, "</align>"); --
