AutoDeleter: do not allow copy

Change-Id: Ieab0fea46fc23c446bbaca407e3e80a4a7901896
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2704
Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
X512
2020-05-16 18:23:09 +00:00
committed by waddlesplash
parent 8ba6597509
commit ec43e4f4c2
2 changed files with 6 additions and 2 deletions
+4
View File
@@ -80,6 +80,10 @@ public:
protected:
C *fObject;
DeleteFunc fDelete;
private:
AutoDeleter(const AutoDeleter&);
AutoDeleter& operator=(const AutoDeleter&);
};
+2 -2
View File
@@ -265,8 +265,8 @@ BDateFormat::GetStartOfWeek(BWeekday* startOfWeek) const
return B_BAD_VALUE;
UErrorCode err = U_ZERO_ERROR;
ObjectDeleter<Calendar> calendar = Calendar::createInstance(
*BFormattingConventions::Private(&fConventions).ICULocale(), err);
ObjectDeleter<Calendar> calendar(Calendar::createInstance(
*BFormattingConventions::Private(&fConventions).ICULocale(), err));
if (U_FAILURE(err))
return B_ERROR;