aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <cbaines8@gmail.com>2012-02-07 21:41:25 +0000
committerChristopher Baines <cbaines8@gmail.com>2012-02-07 21:41:25 +0000
commit7a7d4e326f7698bd5930e70cf01d3d6d1fcd3fcb (patch)
treee13aa1ad1047cae849434c95552dd5e00578fad7
parent9eb2f1d5804d40a92e684237f25342773a4a78c9 (diff)
downloadsouthamptonuniversitymap-7a7d4e326f7698bd5930e70cf01d3d6d1fcd3fcb.tar
southamptonuniversitymap-7a7d4e326f7698bd5930e70cf01d3d6d1fcd3fcb.tar.gz
Fixed a problem, that relates to a bug report on the Android Market.
-rw-r--r--src/net/cbaines/suma/BusStopActivity.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/net/cbaines/suma/BusStopActivity.java b/src/net/cbaines/suma/BusStopActivity.java
index d84bbdd..b711770 100644
--- a/src/net/cbaines/suma/BusStopActivity.java
+++ b/src/net/cbaines/suma/BusStopActivity.java
@@ -237,7 +237,8 @@ public class BusStopActivity extends OrmLiteBaseActivity<DatabaseHelper> impleme
public void onPause() {
if (mHandler != null) { // BusTimes are enabled
mHandler.removeCallbacks(refreshData);
- timetableTask.cancel(true);
+ if (timetableTask != null) // Could happen if the handler has not created the timetableTask yet
+ timetableTask.cancel(true);
Log.i(TAG, "Stoping refreshing timetable data");
}