Programming :: Debugging GTK + Programs Hangs The System?
Oct 28, 2010
A thread-aware version of gdb receives a system notification when a thread starts in the app it is debugging. GTK+ has hidden threads associated with loading icons into menus. So trying to debug a GTK+ program, even one that is apparently single-threaded, can produce a deadlock between gdb, the app and XWindows. The app (actually GdkPixbufLoader) grabs the focus, the mouse and the keyboard and then starts a thread when a menu is opened. If gdb has trouble with threads, it leaves the app blocked but still holding the mouse, et. al. Then you can't talk to gdb or any other GUI interface. To make gdb happy, all GTK+ apps need to be linked with -pthread, if you have the source. If not, gdb cannot be used. In order to break the deadlock, you need a non-GUI shell. If your /etc/inittab starts agetty, mingetty, or the like, and you can get to it with <CRTL><ALT><F3...F6>, you can do a kill -KILL <pid> on the offending app, recover and then go back to XWindows with <CTRL><ALT> <F1/F2>. Otherwise it's reboot time.
View 3 Replies
ADVERTISEMENT
May 21, 2009
Does anyone know how can one improve his debugging skills or how can one narrow down the problem and try to get to the solution ASAP.Or rather how once should approach a problem.I know this is a bit vague question but I want to know how you people approach?
View 3 Replies
View Related
Aug 23, 2010
i need to debug a application which is using many threads. i am using eclipse with GDB debugger but it is not possible to debug it since it has a lot of different threads and i can not not debug it as wre debug in case of single thread(main) . So i would like to know, is there a way to debug such an application, if there is some tutorial that would be nice to know.
View 8 Replies
View Related
Oct 19, 2010
I'm running gdb across a network using gdb server. I've got it up and running. However I can't see any source or variables for my code (in ddd /gdb). At start up gdb says (no debugging symbols found). I've got a g in my make file,
CPFLAGS = -Wall -Os -g -pedantic
I've tried loading symbols in using "symbol-file testarm", this sort of works in that I can view symbols but not names, e.g. if I ask dd to show x y and z, rather than
x = 10
y = 20
x = 30
It says:
display
10/20/30
Also ddd does not show anything in the source window, is there a way I can get it to show this? I think it's because I've started ddd with ddd arm-linux-gdb, as I'm calling a crosscompiler gdb. So can I tell ddd to point to the correct folders? What commands I need to set in gdb/ddd to view variable names (it's hard to keep track when it bunches them all together) and how to view my source code.
View 2 Replies
View Related
Feb 11, 2011
How to switch between processes when debugging with gdb?
View 2 Replies
View Related
Jun 13, 2011
I need to debug "ls". I downloaded coreutils and compiled them in debug mode."ls" uses readdir() kernel API to fetch files/directories from a file system. readdir() fetch data from any file system (suppose FAT or ext3).I have debug version of FAT/ext3 and installed, I also have debug version of coreutils (ls) as well.Now I want to debug from "ls" to "FAT/ext3 readdir()".How to do that?
View 6 Replies
View Related
Dec 5, 2010
I found on the Internet a rough suggestion to debug code which says to add a line:
An example shows this lists the lines of source that do work.
I do not know where these lines are supposed to go and whether the "notdeadyet" should be a call to a subroutine or what. I only found that "%define" is used to link to external files, so I am confused because what I tried did not work.
(I am unable to use (and learn) any debugging tool for another few weeks and I'd like to progress on this If I can.)
View 2 Replies
View Related
Jan 31, 2011
First step will obviously be to compile the QT project with -g option, but how to do that through command line?
View 6 Replies
View Related
Jul 14, 2011
Im using gdb for debugging my application.. I was able to debug child process(when fork comes) .. and in child process we have an exec call to .... So the problem is, when the control come to exec , the exec process is executing at a time... I could not debug the exec. process... error is stack curruption due to same frame So, is there any way to debug the exec process
View 1 Replies
View Related
Feb 24, 2010
I have an environment where i have recursive make files (that is one main and in each directory of a project a file.mk with rules for that directory).Since i'm not the one who wrote it i'm not familiar with it. I would like to explore when i run certain targets how the rules work, which files cause dependency rules to work and why. Also i would like to know ALL the targets that are available to me. i couldn't find any way to 'debug' makefiles or to put it in such debug mode that i see all the information i need when i run a certain target.
View 4 Replies
View Related
Mar 22, 2010
I have started to work with c++ and autotools.
I mainly maintain an application and a shared library as a hobby.
Nothing professional yet, because I want to understand the best practice strongly recommended by advanced professional programmers.
I check out my sources into $HOME/repository and svn creates:
Where I get c++ sources/headers + configure.ac and Makefile.am
Now I need to understand what is considered as a good practice for debugging application, either A), B) or something else.
A) install application and its dependency with:
or
B)
And then I debug the application in the place it was built. [$HOME/repository/app/src/]
View 2 Replies
View Related
Jan 20, 2011
What I am trying to accomplish is a way to read only the lines that have been added to the file mylog0 since the last time the script looped (5 seconds). I am open to new suggestions too, I have been stuck on this little script for a few hours already.
Code: #!/bin/bash
i=0
firstline=0
[code]...
View 2 Replies
View Related
Jan 6, 2011
I wasn't sure where to put this so if I need to move it just let me know.I have a strange problem that I cannot figure out. When I use gdb to debug our rpm-installed program, it says (no debugging symbols found) when it loads. Thing is, when I use nm on the program it can print the symbols, and even stranger is if I use gdb on the program before it is packed up by rpmbuild it loads the debug symbols just fine.Our program is built via the standard make using:GS=-g -Wall-pedantic and as I mentioned I can debug the resulting program. After the build, I package it up using:
cmd="rpmbuild -v -bb ptsnmp.spec --define "ver ${cmvc_release}" --define "rel ${cmvc_level}" --define "_topdir $rpmdir""When this package is installed via rpm, the binary on the machine shows all the debug info via nm, file shows it is not stripped:pt_snmp: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), for GNU/Linux 2.6.9, not strippedyet when I try to debug it I get the no debugging symbols found.This is really taxing my brain and I am sure I am just missing something
View 4 Replies
View Related
Sep 24, 2009
I don't have any problem when I'm communicating with one client. The problem starts when I connect another client.The server eventually ignores the older clients and responds only to the latest one.The working mechanism is simple: Accept connections and print messages received from multiple clients.
View 4 Replies
View Related
Aug 4, 2010
I have Mythbuntu 10.04 installed on an exclusive HTPC and working great... until tonight. After letting the system update some packages (161 packages if I remember right), I suddenly have an issue where the graphical system won't start. After researching I found three error messages that might be causing that.
1. At the start of splash screen I see "UUID=xxxxxxxCD7 not ready yet or not present" I checked in /etc/fstab and found that this is the swap partition. I don't remember seeing this before so this could be the culprit.
2. I'm not at the computer in question right now but I saw a Plymouth error about "mountall" and then the message "plymouth command failed". Not sure if this could be the main error.
3. after a while (usually ca. 1-2 min) I receive thousands of errors of the kind "out of memory"... "kill process XXXX" (process vary wildly e.g. dbus-daemon, mysql, etc)... "process killed"..."respawning"
After error 3, I'm not able to switch to graphical console (ctrl-alt-F7). If I was in the graphical console at this moment, I simply can't switch to the CLI console. I'm always afraid of updating my system since I've seen lots of things breaking afterwards (usually the proprietary graphic drivers) but this is really strange.
View 1 Replies
View Related
Jun 30, 2011
i have 11.04 in my pc.when im using the vlc media player, after playing 5-10 min, its going to be stopped automatically and system will become very slow . so again i am going to restart the system .after restarting the system my theme going be changed . i couldn't figure out whats the problem . help me to get out of this.
View 2 Replies
View Related
Dec 27, 2010
I've got Asus M4AT78T-E motherboard, and so far, I was using 2x1GB of Corsair 1333 Mhz RAM. I decided to change it for 1x2GB OCZ 1600Mhz CL7 memory.
I removed current modules, and installed new one into red colored (they recommend it in user manual) slots. After start, computer hangs at random time, I mean, it could be when Grub loads (while going to select memtest), or even while POST test. (After detecting some SATA device).
Is it possible to run that memory on my computer? Is memory corrupted? I have possibility to use it on another system, but it will be about in next 2-3 weeks, and I'd like to have it here.
View 14 Replies
View Related
Sep 14, 2010
I'm wondering if I can install a program designed for a mac on ubuntu. Would I just run the ./setup file like usual?
View 3 Replies
View Related
Nov 29, 2010
I've always thought that the idea was very cool, but I get restricted by the way distros think that "httpd" and the like are the only things that should go into a runlevel - I mean Fedora doesn't even let you turn off the GUI!I want to do some lower-level hacking than that, so can someone help me?
View 1 Replies
View Related
May 3, 2011
i have two c++ programs, first one captures network packet from eth interface and save it in a file, second one uses this generated file for its purposes, data stream always exists then first program should always be running, although second program cannot read the file while the first program is writing in it, then i need to define a lock which can be checked by both progs before read/write, how is it possible to define this kind of lock in linux?
View 5 Replies
View Related
Oct 18, 2009
I'm running fedora 11 2.6.30.8-64.fc11.i686.PAE. System hangs within 10-12 hours of running almost every day. It happens when nobody at the pc. There is nothing interesting in the log files. Kindly let me know where and what I have to check in this case for solving it.
View 12 Replies
View Related
Dec 23, 2009
I booted up the computer (Fedora 11) and it hung at the blue screen with the F bubble in the middle. I waited for quite sometime without any change to the system I held down the power button to power off and tried starting the computer again with the same result.
When the sytem reboots and I press alt+ctrl+2 i see messages like below on the black screen:Unknown username "root" in message bus configuration file.Could not get password database....Failed to start message bus: Could not get UID and GID for username "dbus"..Please help me get the system up. I saved some data and did not take a backup. Is there's a way I can restore my system to a previous date? Or backup my data somehow?
View 2 Replies
View Related
Jun 11, 2010
Problem with FC13 on a 64 bit box...tried to get Tor and Polipo going and at boot, the system hangs as soon as Polipo starts up. I need to adjust or delete the Polipo service but can't seem to get to any kind of a terminal either...it used to be just hit ctl-alt-and and F key and it dropped to a term. Now that's not happening. Can I do that? And...alternatively, can I force a skip of the Polipo service as it's booting?
View 2 Replies
View Related
Nov 20, 2010
I don't know what I did, but for some reason my fedora system hangs on the OS startup when I use my default kernel. I can still use my other kernel to startup the system though, so it's more of an inconvenience really, but any help fixing it would be appreciated.
The default kernel is Fedora (2.6.34.7-61.fc13.i686) when I start up using this kernel the system hangs(I think I using the right term here, but not sure) after these messages code...
View 12 Replies
View Related
Oct 12, 2010
I'm using a Toshiba satellite U400 and just upgraded from 10.04 LTS to 10.10 and now, every time I try to suspend the PC, it hangs. Before, 10.04 LTS worked perfectly.
I searched ad could only find some talks about 'vt switch' [URL] but couldn't understand if there is a solution to the problem and if yes what is it
View 9 Replies
View Related
Apr 24, 2011
http://ubuntuforums.org/showthread.php?t=1567415
Tried all methods to no avail in 10.10 x32/64. Is there a real fix and why does this happen?
View 3 Replies
View Related
Apr 26, 2011
VLC media player hangs OS when starting, presumably as it loads a new video file (.mp4 in my case). It doesn't happen every time, but after a few days it eventually freezes the system requiring a reset. Google shows many complaints on this, but no fix. Is there a solution?
View 1 Replies
View Related
May 10, 2011
I this problem where my laptop hangs up or suddenly restarts. Currently Iam using Fedora 15 but I had this problem when I was using fedora 13. I upgraded to 15 thinking that may be its been resolved in 15.
I have searched for possible solutions. my system software is up-to-date including the kernel which I took from the test repositeries..
I checked /var/log/messages for possible clues but I have not been able to figure it out. Below is the output of /var/log/messages files just before the laptop freezes or restarts.. so far the below output has been consistent with the event...
Code:
May 10 22:44:11 localhost ntpd[1622]: Listening on routing socket on fd #22 for interface updates
May 10 22:44:11 localhost ntpd[1622]: 0.0.0.0 c016 06 restart
May 10 22:44:11 localhost ntpd[1622]: 0.0.0.0 c012 02 freq_set kernel 16.857 PPM
May 10 22:44:18 localhost ntpd[1622]: 0.0.0.0 c61c 0c clock_step +0.160289 s
May 10 22:44:19 localhost ntpd[1622]: 0.0.0.0 c614 04 freq_mode
[Code]....
View 2 Replies
View Related
Mar 12, 2010
If there is any community or support where electronic programs exist, such as circuit design or programming of "PIC" and to record the "PIC". I appreciate your help! I am very interested as I am a student of Electronics Engineering and also Professor of electronics.
View 1 Replies
View Related
Aug 27, 2010
Anyone know of any linux programs to run a mayan calender?
View 1 Replies
View Related