A failing FindInt32() still modifies the result variable.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39500 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -106,10 +106,9 @@ TermWindow::SessionID::SessionID(int32 id)
|
|||||||
|
|
||||||
|
|
||||||
TermWindow::SessionID::SessionID(const BMessage& message, const char* field)
|
TermWindow::SessionID::SessionID(const BMessage& message, const char* field)
|
||||||
:
|
|
||||||
fID(-1)
|
|
||||||
{
|
{
|
||||||
message.FindInt32(field, &fID);
|
if (message.FindInt32(field, &fID) != B_OK)
|
||||||
|
fID = -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user