Crash happens with html group when setImage try to set an invalid (but non-null) CView #27

Open
opened 3 years ago by ulukyn · 4 comments
ulukyn commented 3 years ago (Migrated from gitlab.com)

To reproduce :
On yubo/gingo, open the cmdzone : /cmdzone show
Open the tool 13
image
Select a template and click LOAD
image
Client crash

Crash happens in :
void CGroupHTML::setImage(CViewBase * view, const string &file, const TImageType type)
Seems the view are not null but invalid

On viewbitmap.cpp we have a good remove code but only for webig, not all other windows

	CViewBitmap::~CViewBitmap()
	{
		if (_HtmlDownload)
		{
			CGroupHTML *groupHtml = dynamic_cast<CGroupHTML*>(CWidgetManager::getInstance()->getElementFromId("ui:interface:webig:content:html"));
			if (groupHtml) {
				groupHtml->removeImageDownload(_HtmlDownload, dynamic_cast<CViewBase*>(this));
				_HtmlDownload = NULL;
			}
		}
	}
To reproduce : On yubo/gingo, open the cmdzone : /cmdzone show Open the tool 13 ![image](/uploads/078cc32200f289f74ca395c1cc9a9e64/image.png) Select a template and click LOAD ![image](/uploads/ba25b6d4c577047e3dff3fcd13c022d1/image.png) Client crash Crash happens in : `void CGroupHTML::setImage(CViewBase * view, const string &file, const TImageType type)` Seems the view are not null but invalid On viewbitmap.cpp we have a good remove code but only for webig, not all other windows ``` CViewBitmap::~CViewBitmap() { if (_HtmlDownload) { CGroupHTML *groupHtml = dynamic_cast<CGroupHTML*>(CWidgetManager::getInstance()->getElementFromId("ui:interface:webig:content:html")); if (groupHtml) { groupHtml->removeImageDownload(_HtmlDownload, dynamic_cast<CViewBase*>(this)); _HtmlDownload = NULL; } } } ```
ulukyn commented 3 years ago (Migrated from gitlab.com)

assigned to @nimetu and @ulukyn

assigned to @nimetu and @ulukyn
ulukyn commented 3 years ago (Migrated from gitlab.com)

@nimetu Ah ok, all images are downloaded from ui:interface:webig:content:html ?

@nimetu Ah ok, all images are downloaded from ui:interface:webig:content:html ?
nimetu commented 3 years ago (Migrated from gitlab.com)

If using setTexture with http texture then its main webig container.

If using setTexture with http texture then its main webig container.
nimetu commented 3 years ago (Migrated from gitlab.com)

mentioned in merge request !25

mentioned in merge request !25
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Ryzom/ryzom-core#27
Loading…
There is no content yet.