diff options
author | Ningyuan Wang <nywang@google.com> | 2017-06-12 20:17:18 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-06-12 20:17:18 +0000 |
commit | 81dece0c57d799d46d7f28d4a1a5a7ff95b579a4 (patch) | |
tree | 1646a3e09c7dd963377fc5d5c00380ecdf2ddc5e /libwifi_system | |
parent | 519f8b12c73981cbf74920e13453c6570c88ef0f (diff) | |
parent | 706ca6ce2d939c02b4813947a397bf7a290f96ab (diff) | |
download | android_frameworks_opt_net_wifi-81dece0c57d799d46d7f28d4a1a5a7ff95b579a4.tar.gz android_frameworks_opt_net_wifi-81dece0c57d799d46d7f28d4a1a5a7ff95b579a4.tar.bz2 android_frameworks_opt_net_wifi-81dece0c57d799d46d7f28d4a1a5a7ff95b579a4.zip |
Merge "Print stat() info on hostapd config file error" into oc-dev
am: 706ca6ce2d
Change-Id: I99bb100cf91e03ca1a57923ccf6477ac27ca81ca
Diffstat (limited to 'libwifi_system')
-rw-r--r-- | libwifi_system/hostapd_manager.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libwifi_system/hostapd_manager.cpp b/libwifi_system/hostapd_manager.cpp index 13bacae22..68184e901 100644 --- a/libwifi_system/hostapd_manager.cpp +++ b/libwifi_system/hostapd_manager.cpp @@ -109,6 +109,14 @@ bool HostapdManager::WriteHostapdConfig(const string& config) { int error = errno; LOG(ERROR) << "Cannot write hostapd config to \"" << kHostapdConfigFilePath << "\": " << strerror(error); + struct stat st; + int result = stat(kHostapdConfigFilePath, &st); + if (result == 0) { + LOG(ERROR) << "hostapd config file uid: "<< st.st_uid << ", gid: " << st.st_gid + << ", mode: " << st.st_mode; + } else { + LOG(ERROR) << "Error calling stat() on hostapd config file: " << strerror(errno); + } return false; } return true; |