summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/macdeployqt/shared/shared.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/macdeployqt/shared/shared.cpp b/src/macdeployqt/shared/shared.cpp
index 5c50efcdc..999342798 100644
--- a/src/macdeployqt/shared/shared.cpp
+++ b/src/macdeployqt/shared/shared.cpp
@@ -187,6 +187,11 @@ OtoolInfo findDependencyInfo(const QString &binaryPath)
QString output = otool.readAllStandardOutput();
QStringList outputLines = output.split("\n", QString::SkipEmptyParts);
+ if (outputLines.size() < 2) {
+ LogError() << "Could not parse otool output:" << output;
+ return info;
+ }
+
outputLines.removeFirst(); // remove line containing the binary path
if (binaryPath.contains(".framework/") || binaryPath.endsWith(".dylib")) {
const auto match = regexp.match(outputLines.first());