From 29d56a4476071b9aafd1fd7af725ee193bdec952 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Fri, 26 Oct 2018 20:49:16 +0000 Subject: cp.pParentWindow is always NULL in NewPWLWindow() Because the CreateParams come from one of the GetCreateParam() overrides, and none of these set that particual field. This implies that the caller will always own the result, since it is never handed off by an AddChild() call, which is consistent with the function return. Change-Id: I1a9f580f347e911855c695807795541282d43f3f Reviewed-on: https://pdfium-review.googlesource.com/c/44691 Commit-Queue: Tom Sepez Reviewed-by: Lei Zhang --- fpdfsdk/formfiller/cffl_listbox.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'fpdfsdk/formfiller/cffl_listbox.cpp') diff --git a/fpdfsdk/formfiller/cffl_listbox.cpp b/fpdfsdk/formfiller/cffl_listbox.cpp index 335073293f..e601c8305e 100644 --- a/fpdfsdk/formfiller/cffl_listbox.cpp +++ b/fpdfsdk/formfiller/cffl_listbox.cpp @@ -43,8 +43,6 @@ std::unique_ptr CFFL_ListBox::NewPWLWindow( const CPWL_Wnd::CreateParams& cp, std::unique_ptr pAttachedData) { auto pWnd = pdfium::MakeUnique(std::move(pAttachedData)); - if (cp.pParentWnd) - cp.pParentWnd->AddChild(pWnd.get()); pWnd->AttachFFLData(this); pWnd->Realize(cp); pWnd->SetFillerNotify(m_pFormFillEnv->GetInteractiveFormFiller()); -- cgit v1.2.3