Ticket #1745 (closed patch: fixed)

Opened 4 years ago

Last modified 4 years ago

QGis crashes dragging a Legend Layer File over a Legend Layer File Group

Reported by: gcarrillo Owned by: mhugent
Priority: critical: causes crash or data corruption Milestone: Version 1.2.0
Component: Map Legend Version: Trunk
Keywords: Drag Legend Layer File Group Cc: pcav
Platform Version: Platform: All
Must Fix for Release: No Awaiting user input: no

Description

QGis crashes dragging a Legend Layer File over a Legend Layer File Group. It happen over center of the item Layer File Group because the Legend Layer File pass to the same level as symbology on the Legend Layer, below center of the Layer File Group the drag works fine. The drag is not allowed to another position.

Attachments

patch_for_bug_1745.txt Download (1.4 KB) - added by gcarrillo 4 years ago.
Patch for bug #1745
screenshot_bug_1745.png Download (56.9 KB) - added by gcarrillo 4 years ago.
This is a screenshot for show the bad behavior in the legend.
legendpatch.diff Download (1.5 KB) - added by mhugent 4 years ago.

Change History

Changed 4 years ago by gcarrillo

Patch for bug #1745

Changed 4 years ago by mhugent

  • type changed from bug to patch

Changed 4 years ago by gcarrillo

This is a screenshot for show the bad behavior in the legend.

Changed 4 years ago by lutra

  • cc pcav added
  • milestone set to Version 1.2.0

Seems to me that this patch has not been applied yet.

Qgis 1.2 trunk under linux crashes (segfault) while qgis 1.2 under windows xp returns "access violation - no RTTI data!" but doesn't crash and remain usable.

Changed 4 years ago by lutra

  • owner changed from gcarrillo to mhugent

Changed 4 years ago by mhugent

Looking at the patch it seems to me that it would be better to handle it in a generic way in qgslegend.cpp (not only for LEGEND_LAYER_FILE and LEGEND_LAYER_FILE_GROUP). I'm nearly about to rush to the train station for holidays. I'm coming back to this ticket in about a week.

Regards, Marco

Changed 4 years ago by lutra

maybe #1439 can be squeezed together with this one

Changed 4 years ago by mhugent

Changed 4 years ago by mhugent

Hi

I don't have the crash on my system, only the move of the legend layer file to the symbology section. 'legendpatch.diff' fixes that in a generic way (only using the return value of dest->accept(), without explicitely mention the concrete classes).

Could you test if this also works for you and if it fixes the crash on your system or not?

Thanks, Marco

Changed 4 years ago by lutra

Hi,

It is pretty easy to reproduce the crash (rev. 11186), see this

 http://www.faunalia.pt/downloads/qgis_legend_crash.mpeg

Now I'll compile the latest revision and try the patch.

Changed 4 years ago by lutra

The pacth works for me (ubuntu 9.04, qgis rev. 11201).

Changed 4 years ago by mhugent

  • status changed from new to closed
  • resolution set to fixed

Ok, so I'm closing this ticket.

Changed 4 years ago by lutra

but it wasn't yet committed, right?

Changed 4 years ago by mhugent

Right, I was too quick with closing :-) Committed now in r11206.

Note: See TracTickets for help on using tickets.