From 458feb0a4485b4cdf13d3705270856ad5fa5fffa Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Beat=20K=C3=BCng?= <beat-kueng@gmx.net>
Date: Wed, 6 Apr 2016 09:51:58 +0200
Subject: [PATCH] fix gpssim: properly handle the case where gpssim is not
 running

---
 src/platforms/posix/drivers/gpssim/gpssim.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/platforms/posix/drivers/gpssim/gpssim.cpp b/src/platforms/posix/drivers/gpssim/gpssim.cpp
index 4bb685ad8f..b4c7af7097 100644
--- a/src/platforms/posix/drivers/gpssim/gpssim.cpp
+++ b/src/platforms/posix/drivers/gpssim/gpssim.cpp
@@ -529,6 +529,7 @@ info()
 {
 	if (g_dev == nullptr) {
 		PX4_ERR("gpssim not running");
+		return;
 	}
 
 	g_dev->print_info();
-- 
GitLab