Remove unused PackageNodeAttribute::fParent

This commit is contained in:
Ingo Weinhold
2011-11-25 06:19:25 +01:00
parent 8b07f87a91
commit 28269859c8
3 changed files with 6 additions and 9 deletions
@@ -1,5 +1,5 @@
/* /*
* Copyright 2009, Ingo Weinhold, [email protected]. * Copyright 2009-2011, Ingo Weinhold, [email protected].
* Distributed under the terms of the MIT License. * Distributed under the terms of the MIT License.
*/ */
@@ -10,11 +10,10 @@
#include <string.h> #include <string.h>
PackageNodeAttribute::PackageNodeAttribute(PackageNode* parent, uint32 type, PackageNodeAttribute::PackageNodeAttribute(uint32 type,
const BPackageData& data) const BPackageData& data)
: :
fData(data), fData(data),
fParent(parent),
fName(NULL), fName(NULL),
fType(type) fType(type)
{ {
@@ -1,5 +1,5 @@
/* /*
* Copyright 2009, Ingo Weinhold, [email protected]. * Copyright 2009-2011, Ingo Weinhold, [email protected].
* Distributed under the terms of the MIT License. * Distributed under the terms of the MIT License.
*/ */
#ifndef PACKAGE_NODE_ATTRIBUTE_H #ifndef PACKAGE_NODE_ATTRIBUTE_H
@@ -19,11 +19,10 @@ class PackageNode;
class PackageNodeAttribute class PackageNodeAttribute
: public DoublyLinkedListLinkImpl<PackageNodeAttribute> { : public DoublyLinkedListLinkImpl<PackageNodeAttribute> {
public: public:
PackageNodeAttribute(PackageNode* parent, PackageNodeAttribute(uint32 type,
uint32 type, const BPackageData& data); const BPackageData& data);
~PackageNodeAttribute(); ~PackageNodeAttribute();
PackageNode* Parent() const { return fParent; }
const char* Name() const { return fName; } const char* Name() const { return fName; }
uint32 Type() const { return fType; } uint32 Type() const { return fType; }
const BPackageData& Data() const { return fData; } const BPackageData& Data() const { return fData; }
@@ -33,7 +32,6 @@ public:
protected: protected:
BPackageData fData; BPackageData fData;
PackageNode* fParent;
char* fName; char* fName;
uint32 fType; uint32 fType;
}; };
@@ -263,7 +263,7 @@ struct Volume::PackageLoaderContentHandler : BPackageContentHandler {
PackageNode* node = (PackageNode*)entry->UserToken(); PackageNode* node = (PackageNode*)entry->UserToken();
PackageNodeAttribute* nodeAttribute = new(std::nothrow) PackageNodeAttribute* nodeAttribute = new(std::nothrow)
PackageNodeAttribute(node, attribute->Type(), attribute->Data()); PackageNodeAttribute(attribute->Type(), attribute->Data());
if (nodeAttribute == NULL) if (nodeAttribute == NULL)
RETURN_ERROR(B_NO_MEMORY) RETURN_ERROR(B_NO_MEMORY)