std::nothrow in glibc from gcc6.2 cannot linked with ASLR enabled
executable in x86 series architectures but don't know why...
So just use default new and handle std::bad_alloc.
Change-Id: I21191c108e94be4ca2c7157807407f8f6ec5f4d3
Signed-off-by: Kyungwook Tak <k.tak@samsung.com>
pDb = pDBConnectionInfo->pDBConnection;
} else {
DRM_TAPPS_LOG("no connection exists..");
- std::unique_ptr<DtappsDBConnectionInfo> pDBConnectionInfo(
- new(std::nothrow) DtappsDBConnectionInfo);
-
- if (pDBConnectionInfo == NULL)
+ std::unique_ptr<DtappsDBConnectionInfo> pDBConnectionInfo;
+ try {
+ pDBConnectionInfo.reset(new DtappsDBConnectionInfo);
+ } catch (const std::bad_alloc &) {
return FALSE;
+ }
DRM_TAPPS_FRQ_LOG("Opening DB connection.");