diff options
author | Mika Liljeberg <mika.liljeberg@nokia.com> | 2010-11-10 14:22:29 +0200 |
---|---|---|
committer | Aki Niemi <aki.niemi@nokia.com> | 2010-11-11 09:23:33 +0200 |
commit | 6fa4ee0237b8696db6459eb61375100c21bb7e40 (patch) | |
tree | 35b6b4f1384a778432d5abc346a61b10ccbf5744 | |
parent | 39823fee142013f20b5db60ea4b555098f93c978 (diff) | |
download | ofono-6fa4ee0237b8696db6459eb61375100c21bb7e40.tar.bz2 |
gisi: return NULL instead of asserting
-rw-r--r-- | gisi/pep.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -148,6 +148,8 @@ unsigned g_isi_pep_get_ifindex(const GIsiPEP *pep) char *g_isi_pep_get_ifname(const GIsiPEP *pep, char *ifname) { - unsigned ifi = g_isi_pep_get_ifindex(pep); - return if_indextoname(ifi, ifname); + if (pep->gprs_fd == -1) + return NULL; + + return if_indextoname(g_isi_pep_get_ifindex(pep), ifname); } |