CID 5899: Move a variable so it does not go out of scope when a pointer to it

is used. In my testing this did not seem to be a problem but it doesn't hurt to
fix it.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40012 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ryan Leavengood 2010-12-29 05:34:50 +00:00
parent ccb228004c
commit 5b9003c79e
1 changed files with 1 additions and 1 deletions

View File

@ -741,8 +741,8 @@ StyledEditWindow::SaveAs(BMessage* message)
{
if (fSavePanel == NULL) {
entry_ref* directory = NULL;
if (fSaveMessage != NULL) {
entry_ref dirRef;
if (fSaveMessage != NULL) {
if (fSaveMessage->FindRef("directory", &dirRef) == B_OK)
directory = &dirRef;
}