Network preferences: Uninitialized pointers.
CID 1251080, 1251077, 1251076, 1251075, 1251068
This commit is contained in:
@@ -12,24 +12,36 @@
|
|||||||
NetworkSetupProfile::NetworkSetupProfile()
|
NetworkSetupProfile::NetworkSetupProfile()
|
||||||
:
|
:
|
||||||
fRoot(new BEntry()),
|
fRoot(new BEntry()),
|
||||||
fPath(new BPath())
|
fPath(new BPath()),
|
||||||
|
fName(NULL),
|
||||||
|
fIsCurrent(false),
|
||||||
|
fIsDefault(false)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
NetworkSetupProfile::NetworkSetupProfile(const char* path)
|
NetworkSetupProfile::NetworkSetupProfile(const char* path)
|
||||||
|
:
|
||||||
|
fIsCurrent(false),
|
||||||
|
fIsDefault(false)
|
||||||
{
|
{
|
||||||
SetTo(path);
|
SetTo(path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
NetworkSetupProfile::NetworkSetupProfile(const entry_ref* ref)
|
NetworkSetupProfile::NetworkSetupProfile(const entry_ref* ref)
|
||||||
|
:
|
||||||
|
fIsCurrent(false),
|
||||||
|
fIsDefault(false)
|
||||||
{
|
{
|
||||||
SetTo(ref);
|
SetTo(ref);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
NetworkSetupProfile::NetworkSetupProfile(BEntry* entry)
|
NetworkSetupProfile::NetworkSetupProfile(BEntry* entry)
|
||||||
|
:
|
||||||
|
fIsCurrent(false),
|
||||||
|
fIsDefault(false)
|
||||||
{
|
{
|
||||||
SetTo(entry);
|
SetTo(entry);
|
||||||
}
|
}
|
||||||
@@ -38,6 +50,7 @@ NetworkSetupProfile::NetworkSetupProfile(BEntry* entry)
|
|||||||
NetworkSetupProfile::~NetworkSetupProfile()
|
NetworkSetupProfile::~NetworkSetupProfile()
|
||||||
{
|
{
|
||||||
delete fRoot;
|
delete fRoot;
|
||||||
|
delete fPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -63,6 +76,8 @@ NetworkSetupProfile::SetTo(BEntry *entry)
|
|||||||
delete fRoot;
|
delete fRoot;
|
||||||
delete fPath;
|
delete fPath;
|
||||||
fRoot = entry;
|
fRoot = entry;
|
||||||
|
fPath = NULL;
|
||||||
|
fName = NULL;
|
||||||
return B_OK;
|
return B_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user