summaryrefslogtreecommitdiffstats
path: root/plugins/mbpi.c
diff options
context:
space:
mode:
authorOleg Zhurakivskyy <oleg.zhurakivskyy@intel.com>2011-10-05 16:18:28 +0300
committerDenis Kenzior <denkenz@gmail.com>2011-10-12 16:30:33 -0500
commit3501d76b94c6d1983899557f7acd8f3d19332292 (patch)
treec0049616726b84fac6bfbebbec0da5d15fb5a242 /plugins/mbpi.c
parentd02e0c42b6d9a3f67d22f8b2ec6c9f2ef745cc37 (diff)
downloadofono-3501d76b94c6d1983899557f7acd8f3d19332292.tar.bz2
mbpi: Improve mbpi_lookup() error reporting
Diffstat (limited to 'plugins/mbpi.c')
-rw-r--r--plugins/mbpi.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/plugins/mbpi.c b/plugins/mbpi.c
index d709d9c5..f6fd1376 100644
--- a/plugins/mbpi.c
+++ b/plugins/mbpi.c
@@ -378,7 +378,8 @@ GSList *mbpi_lookup(const char *mcc, const char *mnc,
if (fd < 0) {
g_set_error(error, G_FILE_ERROR,
g_file_error_from_errno(errno),
- "open failed: %s", g_strerror(errno));
+ "open(%s) failed: %s", MBPI_DATABASE,
+ g_strerror(errno));
return NULL;
}
@@ -386,7 +387,8 @@ GSList *mbpi_lookup(const char *mcc, const char *mnc,
close(fd);
g_set_error(error, G_FILE_ERROR,
g_file_error_from_errno(errno),
- "fstat failed: %s", g_strerror(errno));
+ "fstat(%s) failed: %s", MBPI_DATABASE,
+ g_strerror(errno));
return NULL;
}
@@ -395,7 +397,8 @@ GSList *mbpi_lookup(const char *mcc, const char *mnc,
close(fd);
g_set_error(error, G_FILE_ERROR,
g_file_error_from_errno(errno),
- "mmap failed: %s", g_strerror(errno));
+ "mmap(%s) failed: %s", MBPI_DATABASE,
+ g_strerror(errno));
return NULL;
}