From 7010f43fec3f2ac8ba38b4ebe0c1e148c7e57e4e Mon Sep 17 00:00:00 2001 From: Uwe Seimet Date: Wed, 23 Oct 2024 18:14:04 +0200 Subject: [PATCH] Update s2pexec error handling --- cpp/s2pexec/s2pexec_core.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cpp/s2pexec/s2pexec_core.cpp b/cpp/s2pexec/s2pexec_core.cpp index 8535540e..94c2fa02 100644 --- a/cpp/s2pexec/s2pexec_core.cpp +++ b/cpp/s2pexec/s2pexec_core.cpp @@ -355,6 +355,11 @@ int S2pExec::Run(span args, bool in_process) return -1; } + if (command.empy()) { + cerr << "Error: Missing command" << endl; + return -1; + } + if (!Init(in_process)) { cerr << "Error: Can't initialize bus" << endl; return -1;