Bug report #132

qgis crashes when viewing PostGIS tables

Added by Redmine Admin almost 18 years ago. Updated over 14 years ago.

Status:Closed
Priority:Low
Assignee:Gary Sherman
Category:Data Provider
Affected QGIS version: Regression?:No
Operating System:Debian Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:10191

Description

When opening a PostGIS table, in various situations we get:
Warning: QPainter::begin(): Painter is already active.
You must end() the painter before a second begin()
Segmentation fault
This happens eg if we click on the table icon after inserting a point and committing changes, or when we allow editing, select a point, and click on the "cut" icon.

In one occasion, we also got:
Warning: X Error: BadWindow (invalid Window parameter) 3
Major opcode: 20 (X_GetProperty)
Resource id: 0x1603586
before segfaulting.

History

#1 Updated by Redmine Admin almost 18 years ago

After recent commit by mhugent (#5507) things have improved, but not solved; the crash does not occur in the first case (click on the table icon after inserting a point and committing changes), but it does in the second case (allow editing, select a point, and click on the "cut" icon).

#2 Updated by Marco Hugentobler almost 18 years ago

I am not able to reproduce the second crash with my database. Do you have a debug version and a backtrace? Or what is the console output (besides the QPainter warning, which can be ignored)?

#3 Updated by Redmine Admin almost 18 years ago

This is an strace (last lines):

ioctl(7, FIONREAD, d028a068 (SVN r33)) = 0
read(7, "\\5\\1:\\276d\\3012\\262L\\0\\0\\0\\330\\0@\\3\\0\\0\\0\\0;\\3M\\0\\22\\0"..., 32) = 32
gettimeofday({1149745938, 789955}, NULL) = 0
write(4, "\\0", 1) = 1
rt_sigprocmask(SIG_BLOCK, [PIPE], [], 8) = 0
send(10, "Q\\0\\0\\0\
end work\\0", 14, 0) = 14
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
poll([{fd=10, events=POLLIN|POLLERR, revents=POLLIN}], 1, 1) = 1
recv(10, "C\\0\\0\\0\\vCOMMIT\\0Z\\0\\0\\0\\5I", 16384, 0) = 18
rt_sigprocmask(SIG_BLOCK, [PIPE], [], 8) = 0
send(10, "Q\\0\\0\\0\\17begin work\\0", 16, 0) = 16
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
poll([{fd=10, events=POLLIN|POLLERR, revents=POLLIN}], 1, -1) = 1
recv(10, "C\\0\\0\\0\
BEGIN\\0Z\\0\\0\\0\\5T", 16384, 0) = 17
rt_sigprocmask(SIG_BLOCK, [PIPE], [], 8) = 0
send(10, "Q\\0\\0\\0wdeclare qgisf binary cursor"..., 120, 0) = 120
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
poll([{fd=10, events=POLLIN|POLLERR, revents=POLLIN}], 1, -1) = 1
recv(10, "C\\0\\0\\0\\23DECLARE CURSOR\\0Z\\0\\0\\0\\5T", 16384, 0) = 26
rt_sigprocmask(SIG_BLOCK, [PIPE], [], 8) = 0
send(10, "Q\\0\\0\\0\\37fetch forward 1 from qgisf\\0", 32, 0) = 32
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
poll([{fd=10, events=POLLIN|POLLERR, revents=POLLIN}], 1, -1) = 1
recv(10, "T\\0\\0\\0C\\0\\2cat\\0\\0<\\32\\31\\0\\1\\0\\0\\0\\27\\0\\4\\377\\377\\377"..., 16384, 0) = 125
rt_sigprocmask(SIG_BLOCK, [PIPE], [], 8) = 0
send(10, "Q\\0\\0\\0\\37fetch forward 1 from qgisf\\0", 32, 0) = 32
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
poll([{fd=10, events=POLLIN|POLLERR, revents=POLLIN}], 1, -1) = 1
recv(10, "T\\0\\0\\0C\\0\\2cat\\0\\0<\\32\\31\\0\\1\\0\\0\\0\\27\\0\\4\\377\\377\\377"..., 16384, 0) = 104
--
SIGSEGV (Segmentation fault) @ 0 (0) ---
++ killed by SIGSEGV ++
Process 18736 detached

#4 Updated by Redmine Admin almost 18 years ago

apparently this has been fixed. please somebody else check it and close the bug if appropriate

#5 Updated by Gavin Macaulay - almost 18 years ago

  • Status changed from Open to Closed
  • Resolution set to fixed

This problem appears to be resolved. Reopen if not...

#6 Updated by Anonymous over 14 years ago

Milestone Version 0.8 deleted

Also available in: Atom PDF