@@ -23,7 +23,7 @@ namespace NEO {
2323
2424bool D3DSharingContextBuilder<D3DTypesHelper::D3D9>::processProperties(cl_context_properties &propertyType, cl_context_properties &propertyValue, cl_int &errcodeRet) {
2525 if (contextData.get () == nullptr ) {
26- contextData. reset ( new D3DCreateContextProperties<D3DTypesHelper::D3D9>);
26+ contextData = std::make_unique< D3DCreateContextProperties<D3DTypesHelper::D3D9>>( );
2727 }
2828 bool res = false ;
2929
@@ -44,7 +44,7 @@ bool D3DSharingContextBuilder<D3DTypesHelper::D3D9>::processProperties(cl_contex
4444
4545bool D3DSharingContextBuilder<D3DTypesHelper::D3D10>::processProperties(cl_context_properties &propertyType, cl_context_properties &propertyValue, cl_int &errcodeRet) {
4646 if (contextData.get () == nullptr ) {
47- contextData. reset ( new D3DCreateContextProperties<D3DTypesHelper::D3D10>);
47+ contextData = std::make_unique< D3DCreateContextProperties<D3DTypesHelper::D3D10>>( );
4848 }
4949 bool res = false ;
5050
@@ -60,7 +60,7 @@ bool D3DSharingContextBuilder<D3DTypesHelper::D3D10>::processProperties(cl_conte
6060
6161bool D3DSharingContextBuilder<D3DTypesHelper::D3D11>::processProperties(cl_context_properties &propertyType, cl_context_properties &propertyValue, cl_int &errcodeRet) {
6262 if (contextData.get () == nullptr ) {
63- contextData. reset ( new D3DCreateContextProperties<D3DTypesHelper::D3D11>);
63+ contextData = std::make_unique< D3DCreateContextProperties<D3DTypesHelper::D3D11>>( );
6464 }
6565 bool res = false ;
6666 switch (propertyType) {
@@ -99,7 +99,7 @@ bool D3DSharingContextBuilder<D3D>::finalizeProperties(Context &context, int32_t
9999
100100template <typename D3D>
101101std::unique_ptr<SharingContextBuilder> D3DSharingBuilderFactory<D3D>::createContextBuilder() {
102- return std::unique_ptr<SharingContextBuilder>( new D3DSharingContextBuilder<D3D>() );
102+ return std::make_unique< D3DSharingContextBuilder<D3D>>( );
103103};
104104
105105std::string D3DSharingBuilderFactory<D3DTypesHelper::D3D9>::getExtensions() {
0 commit comments