Make sure configuration is saved to storage device

Bug: 20891664

Change-Id: I9bec042155f13bec678944466082a9969e559851
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
diff --git a/wpa_supplicant/config_file.c b/wpa_supplicant/config_file.c
index ae34f10..aeea70c 100644
--- a/wpa_supplicant/config_file.c
+++ b/wpa_supplicant/config_file.c
@@ -1353,6 +1353,8 @@
 	}
 #endif /* CONFIG_NO_CONFIG_BLOBS */
 
+	os_fsync(f);
+
 	fclose(f);
 
 	if (tmp_name) {