mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 04:12:43 +00:00 
			
		
		
		
	HackStudio: Make a new ProjectBuilder object when opening a project
We couldn't compile a project after creating it, because the project builder was still holding a reference to the previous freed project. Fixes: #15715
This commit is contained in:
		
							parent
							
								
									98fa3736ed
								
							
						
					
					
						commit
						b67762a7f3
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -185,7 +185,6 @@ ErrorOr<NonnullRefPtr<HackStudioWidget>> HackStudioWidget::create(DeprecatedStri | |||
|         }; | ||||
|     } | ||||
| 
 | ||||
|     widget->m_project_builder = make<ProjectBuilder>(*widget->m_terminal_wrapper, *widget->m_project); | ||||
|     widget->project().model().set_should_show_dotfiles(Config::read_bool("HackStudio"sv, "Global"sv, "ShowDotfiles"sv, false)); | ||||
| 
 | ||||
|     return widget; | ||||
|  | @ -252,6 +251,7 @@ void HackStudioWidget::open_project(DeprecatedString const& root_path) | |||
|     } | ||||
|     m_project = Project::open_with_root_path(root_path); | ||||
|     VERIFY(m_project); | ||||
|     m_project_builder = make<ProjectBuilder>(*m_terminal_wrapper, *m_project); | ||||
|     if (m_project_tree_view) { | ||||
|         m_project_tree_view->set_model(m_project->model()); | ||||
|         m_project_tree_view->update(); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Karol Kosek
						Karol Kosek