Github #123 Catch exceptions by reference
Change-Id: Ie664cb7127434ad9c7a03c4a31f3c71fdebd49b9
Signed-off-by: Matthew Bentham <Matthew.Bentham@arm.com>
diff --git a/src/armnn/LayerSupport.cpp b/src/armnn/LayerSupport.cpp
index 484251c..12b3c40 100644
--- a/src/armnn/LayerSupport.cpp
+++ b/src/armnn/LayerSupport.cpp
@@ -58,7 +58,7 @@
isSupported = layerSupportObject->func(__VA_ARGS__, Optional<std::string&>(reasonIfUnsupportedFull)); \
CopyErrorMessage(reasonIfUnsupported, reasonIfUnsupportedFull.c_str(), reasonIfUnsupportedMaxLength); \
} \
- } catch (InvalidArgumentException e) { \
+ } catch (const InvalidArgumentException &e) { \
/* re-throwing with more context information */ \
throw InvalidArgumentException(e, "Failed to check layer support", CHECK_LOCATION()); \
} \