summaryrefslogtreecommitdiff
path: root/libmodprobe/libmodprobe.cpp
diff options
context:
space:
mode:
authorAndrew Scull <ascull@google.com>2020-10-18 17:37:27 +0100
committerAndrew Scull <ascull@google.com>2020-10-19 12:00:08 +0100
commitfb18f6ef059dc2d20fa58cdcc9609bf768a11753 (patch)
treefa19dad54b3fee35a730d96aa9b6033cdc63d325 /libmodprobe/libmodprobe.cpp
parentf9c36a2ca632fa88edba9c2c87f14f2aec1e7fd3 (diff)
libmodprobe: Fail when modules.dep lacks colon
The first argument in a modules.dep line must end with a colon so fail if that condition is not met. Test: libmodprobe_tests Change-Id: I6f3a22758302f16b924e5a16f7af9bf35f1a56f3
Diffstat (limited to 'libmodprobe/libmodprobe.cpp')
-rw-r--r--libmodprobe/libmodprobe.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/libmodprobe/libmodprobe.cpp b/libmodprobe/libmodprobe.cpp
index ceabf626c..b3ae93785 100644
--- a/libmodprobe/libmodprobe.cpp
+++ b/libmodprobe/libmodprobe.cpp
@@ -66,6 +66,7 @@ bool Modprobe::ParseDepCallback(const std::string& base_path,
deps.emplace_back(prefix + args[0].substr(0, pos));
} else {
LOG(ERROR) << "dependency lines must start with name followed by ':'";
+ return false;
}
// Remaining items are dependencies of our module