From 2cfd565ffa8071bd767b74ea2dc7f7538c5c58b5 Mon Sep 17 00:00:00 2001 From: Seonah Moon Date: Wed, 5 Apr 2017 13:19:18 +0900 Subject: [PATCH] Fixed build error on gcc62 readdir_r() is deprecated. It should be replaced with reddir(). Change-Id: I0ec9fd2ad60c39bb0585ef617b756b0996262cd4 Signed-off-by: Seonah Moon --- packaging/net-config.spec | 2 +- src/wifi-config.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/packaging/net-config.spec b/packaging/net-config.spec index f2588c8..5bfe946 100755 --- a/packaging/net-config.spec +++ b/packaging/net-config.spec @@ -1,6 +1,6 @@ Name: net-config Summary: TIZEN Network Configuration service -Version: 1.1.105 +Version: 1.1.106 Release: 2 Group: System/Network License: Apache-2.0 diff --git a/src/wifi-config.c b/src/wifi-config.c index 1f479a3..41297d5 100755 --- a/src/wifi-config.c +++ b/src/wifi-config.c @@ -543,7 +543,6 @@ static gboolean _get_field(const gchar *config_id, const gchar *key, gchar **val static GSList *_get_list(void) { GSList *list = NULL; - struct dirent de; struct dirent *dp = NULL; DIR *dir; @@ -553,7 +552,7 @@ static GSList *_get_list(void) return NULL; } - while ((readdir_r(dir, &de, &dp) == 0) && (dp != NULL)) { + while ((readdir(dir) == 0) && (dp != NULL)) { if (g_strcmp0(dp->d_name, ".") == 0 || g_strcmp0(dp->d_name, "..") == 0 || strncmp(dp->d_name, WIFI_CONFIG_PREFIX, strlen(WIFI_CONFIG_PREFIX)) != 0) { continue; -- 2.7.4