From: Amos Jeffries Date: Fri, 2 May 2014 07:49:18 +0000 (-0700) Subject: Resolve 'dying from an unhandled exception: c' X-Git-Tag: SQUID_3_4_5~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=00717f21b8111f4f309f07077bcd36e15b9beac6;p=thirdparty%2Fsquid.git Resolve 'dying from an unhandled exception: c' CbcPointer<> is used from code outside of Job protection where it is safe to use Must(). In order to get a useful backtrace we need to assert immediately at the point of failure. Particularly necessary since these are in generic operators used "everywhere" in the code. --- diff --git a/src/base/CbcPointer.h b/src/base/CbcPointer.h index 51c86b125e..3bed8db2aa 100644 --- a/src/base/CbcPointer.h +++ b/src/base/CbcPointer.h @@ -135,7 +135,7 @@ Cbc & CbcPointer::operator *() const { Cbc *c = get(); - Must(c); + assert(c); return *c; } @@ -144,7 +144,7 @@ Cbc * CbcPointer::operator ->() const { Cbc *c = get(); - Must(c); + assert(c); return c; }