btrfs: Attempt to fix GCC2 build.
[haiku.git] / src / servers / package / Package.cpp
blob224b8cc86cc20870b2d1dc5d8393fa07cb7e3b50
1 /*
2 * Copyright 2013-2014, Haiku, Inc. All Rights Reserved.
3 * Distributed under the terms of the MIT License.
5 * Authors:
6 * Ingo Weinhold <ingo_weinhold@gmx.de>
7 */
10 #include "Package.h"
12 #include <fcntl.h>
14 #include <File.h>
16 #include <AutoDeleter.h>
18 #include "DebugSupport.h"
21 Package::Package(PackageFile* file)
23 fFile(file),
24 fActive(false),
25 fFileNameHashTableNext(NULL),
26 fNodeRefHashTableNext(NULL)
28 fFile->AcquireReference();
32 Package::~Package()
34 fFile->ReleaseReference();
38 Package*
39 Package::Clone() const
41 Package* clone = new(std::nothrow) Package(fFile);
42 if (clone != NULL)
43 clone->fActive = fActive;
44 return clone;