From 71947e478cafc7f379801e26e097fbdc6cd122f8 Mon Sep 17 00:00:00 2001 From: Alex Wilson Date: Tue, 15 Feb 2011 20:34:47 +0000 Subject: [PATCH] When unarchiving a BSplitLayout, initialize our members properly so that even if unarchiving fails, the object is in a usable state. Fixes CID 10045. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40522 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kits/interface/SplitLayout.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/kits/interface/SplitLayout.cpp b/src/kits/interface/SplitLayout.cpp index d35bb7c5ff..ba4ae1b658 100644 --- a/src/kits/interface/SplitLayout.cpp +++ b/src/kits/interface/SplitLayout.cpp @@ -198,6 +198,14 @@ BSplitLayout::BSplitLayout(enum orientation orientation, BSplitLayout::BSplitLayout(BMessage* from) : BAbstractLayout(BUnarchiver::PrepareArchive(from)), + fOrientation(B_HORIZONTAL), + fLeftInset(0), + fRightInset(0), + fTopInset(0), + fBottomInset(0), + fSplitterSize(6), + fSpacing(be_control_look->DefaultItemSpacing()), + fSplitterItems(), fVisibleItems(), fMin(),