From d05799e4718d219d0c8613ad3c34592ea4a2f86b Mon Sep 17 00:00:00 2001 From: Nelle Varoquaux Date: Tue, 5 Feb 2019 10:54:14 -0800 Subject: [PATCH] Backport PR #13365: Fix gcc warning --- src/_tkagg.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/_tkagg.cpp b/src/_tkagg.cpp index 1d690f4f4e00..7be9ad2fcbd9 100644 --- a/src/_tkagg.cpp +++ b/src/_tkagg.cpp @@ -114,7 +114,7 @@ static int PyAggImagePhoto(ClientData clientdata, Tcl_Interp *interp, int try { destbuffer = new agg::int8u[deststride * destheight]; } - catch (std::bad_alloc) { + catch (const std::bad_alloc &) { TCL_APPEND_RESULT(interp, "could not allocate memory", (char *)NULL); return TCL_ERROR; }