diff options
author | Denis Kenzior <denkenz@gmail.com> | 2010-10-11 20:13:08 -0500 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2010-10-13 05:04:46 -0500 |
commit | f4c66f67df49405c9c1fb53bb5de1ff2d7a4b6c2 (patch) | |
tree | c6a51fb019ea18254d561af54c914269a715b2bb /src | |
parent | 413c200dfb0fd2cb472e95bb3753e08e10cd0c9e (diff) | |
download | ofono-f4c66f67df49405c9c1fb53bb5de1ff2d7a4b6c2.tar.bz2 |
simfs: Don't try to read image cache imsi is null
Diffstat (limited to 'src')
-rw-r--r-- | src/simfs.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/simfs.c b/src/simfs.c index 6865230d..0b554868 100644 --- a/src/simfs.c +++ b/src/simfs.c @@ -756,8 +756,10 @@ char *sim_fs_get_cached_image(struct sim_fs *fs, int id) return NULL; imsi = ofono_sim_get_imsi(fs->sim); - phase = ofono_sim_get_phase(fs->sim); + if (imsi == NULL) + return NULL; + phase = ofono_sim_get_phase(fs->sim); path = g_strdup_printf(SIM_IMAGE_CACHE_PATH, imsi, phase, id); TFR(stat(path, &st_buf)); |