Cannot Insert Breakpoint 2. Error Accessing Memory Address Input/output Error
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings gdb cannot insert breakpoint cannot access memory at address and policies of this site About Us Learn more about Stack Overflow gdb break cannot access memory at address the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation error in re-setting breakpoint 1: cannot access memory at address Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it gdb cannot insert breakpoint 0 only takes a minute: Sign up After setting a breakpoint in Qt, gdb says: “Error accessing memory address” up vote 5 down vote favorite 1 I wrote a very simple Qt program here: int main(int argc, char* argv[]) { QApplication app(argc, argv); QTableView table(&frame); table.resize(100, 100); table.show(); return app.exec(); } And when I try to set a breakpoint where the
Gdb Cannot Access Memory At Address
table gets clicked, I get this error from gdb: (gdb) symbol-file /usr/lib/libQtGui.so.4.4.3.debug Load new symbol table from "/usr/lib/libQtGui.so.4.4.3.debug"? (y or n) y Reading symbols from /usr/lib/libQtGui.so.4.4.3.debug...done. (gdb) br 'QAbstractItemView::clicked(QModelIndex const&)' Breakpoint 1 at 0x5fc660: file .moc/release-shared/moc_qabstractitemview.cpp, line 313. (gdb) run Starting program: ./qt-test Warning: Cannot insert breakpoint 1. Error accessing memory address 0x5fc660: Input/output error. Does anyone know why the breakpoint can't be inserted? debugging qt qt4 gdb breakpoints share|improve this question edited Jul 14 '09 at 6:19 Quinn Taylor 36.6k1395118 asked May 26 '09 at 21:18 Neil 10k73448 I'm using Ubuntu Intrepid, and I have installed libqt4-dbg, if that helps at all. –Neil May 26 '09 at 21:22 add a comment| 4 Answers 4 active oldest votes up vote 2 down vote accepted If you want to automatically break in main without setting a breakpoint you can also use the start command. If you need to provide any arguments to the program you can use: start argument1 argument2 share|improve this answer edited May 29 '09 at 9:27 answered May 28 '09 at 20:57 Andy 2
to check the nightly builds in the forum. Home Help Search Login Register Wiki Code::Blocks » User forums » Help » GDB having problems setting breakpoints. « previous next » Send this topic Print Pages: [1] Go Down Author Topic: GDB having problems setting breakpoints. (Read 8757 times) zalzane Single posting newcomer Posts: http://stackoverflow.com/questions/912808/after-setting-a-breakpoint-in-qt-gdb-says-error-accessing-memory-address 7 GDB having problems setting breakpoints. « on: June 09, 2011, 11:11:08 pm » So what I do is set a breakpoint inside this one constructor, and go to start debug. The full debug console then spews out this info:Code: [Select]PATH=.;G:\Infinita\SDL-1.2.14\include;G:\Infinita\SDL-1.2.14\lib;O:\CodeBlocks\MinGW\bin;E:\Windows\system32;E:\Windows;E:\Windows\System32\Wbem;E:\Windows\System32\WindowsPowerShell\v1.0\
Command-line: O:\CodeBlocks\MinGW\bin\gdb.exe -nx -fullname -quiet -args http://forums.codeblocks.org/index.php?topic=14847.0 bin/Debug/Infinita.exe
Working dir : G:\Infinita\
> set prompt >>>>>>cb_gdb:
Reading symbols from G:\Infinita/bin/Debug/Infinita.exe...done.
(gdb) >>>>>>cb_gdb:
> show version
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-mingw32".
For bug reporting instructions, please see:
>>>>>>cb_gdb:
> set confirm off
>>>>>>cb_gdb:
> set width 0
>>>>>>cb_gdb:
> set height 0
>>>>>>cb_gdb:
> set breakpoint pending on
>>>>>>cb_gdb:
> set print asm-demangle on
>>>>>>cb_gdb:
> set unwindonsignal on
>>>>>>cb_gdb:
> set debugevents on
>>>>>>cb_gdb:
> set new-console on
>>>>>>cb_gdb:
> set disassembly-flavor att
>>>>>>cb_gdb:
> catch throw
Catchpoint 1 (throw)
>>>>>>cb_gdb:
> source O:\CodeBl
-Clone This Bug -Last Comment First Last Prev Next This bug is not https://bugzilla.redhat.com/show_bug.cgi?id=678098 in your last search results. Bug678098 - Cannot set breakpoints in gdb Summary: Cannot set breakpoints in gdb Status: CLOSED WONTFIX Aliases: None Product: Fedora Classification: Fedora http://forum.lazarus.freepascal.org/index.php?topic=10317.0 Component: gdb (Show other bugs) Sub Component: --- Version: 14 Hardware: x86_64 Linux Priority unspecified Severity unspecified TargetMilestone: --- TargetRelease: --- Assigned To: Jan Kratochvil QA Contact: Fedora cannot access Extras Quality Assurance Docs Contact: URL: Whiteboard: Keywords: Depends On: Blocks: Show dependency tree /graph Reported: 2011-02-16 12:31 EST by Javier Jardón Modified: 2012-08-16 09:29 EDT (History) CC List: 3 users (show) jan.kratochvil pmuldoon sergiodj See Also: Fixed In Version: Doc Type: Bug Fix Doc Text: Story Points: --- Clone Of: Environment: Last Closed: cannot access memory 2012-08-16 09:29:54 EDT Type: --- Regression: --- Mount Type: --- Documentation: --- CRM: Verified Versions: Category: --- oVirt Team: --- RHEL 7.3 requirements from Atomic Host: Cloudforms Team: --- Attachments (Terms of Use) Add an attachment (proposed patch, testcase, etc.) Groups: None (edit) Description Javier Jardón 2011-02-16 12:31:42 EST I have a strange behaviour in gdb: I can't set breakpoints, this is the error: "Cannot insert breakpoint 1. Error accessing memory address 0x3b24481778: Input/output error." It's not related with SELinux, as I disabled selinux (SELINUX=permissive in /etc/selinux/config) and the problem persist. If you need any more info, please tell me. Comment 1 Jan Kratochvil 2011-02-16 12:55:57 EST (In reply to comment #0) > I have a strange behaviour in gdb: I can't set breakpoints, this is the error: > > "Cannot insert breakpoint 1. > Error accessing memory address 0x3b24481778: Input/output error." A reproducer would be the best one. Otherwise I need at least: (gdb) info breakpoints 1 and either (gdb) info proc ma
FAQ Wiki Bugtracker IRC channel Developer Blog Follow us on Twitter Latest SVN Mailing List Other languages Foundation Website Useful Wiki Links Project Roadmap Getting the Source Screenshots About donations (wiki) Bookstore Computer Math and Games in Pascal Lazarus, the complete guide (only a few left) Search Advanced search « previous next » Print Pages: [1] Author Topic: How to reset gdb settings (Read 13798 times) jagorath New member Posts: 34 How to reset gdb settings « on: August 26, 2010, 02:17:50 am » I seem to have completely hosed my debugger settings within Lazarus somehow, is there a way to clear the settings so they will be restored to the default? Perhaps by deleting an .ini file?Currently I have to run without a debugger specified because if I specify one the application doesn't run. Logged Martin_fr Administrator Hero Member Posts: 4029 Re: How to reset gdb settings « Reply #1 on: August 26, 2010, 02:31:43 am » There aren't many debugger related settings, and I am not sure, if the default will be of much use (since you need to specify at least the location of gdb.exe)Lazarus settings are in the user folder/home/name/.lazarus/*C:\Users\name\AppData\Local\lazarus\*Make a backupOther setting are in your project.lpiproject.lpslps is optional, and may either be in project dir, or the above user dirC:\Users\name\AppData\Local\lazarus\projectsessions-----------Better is to just set debugger type = gdband select a gdb.exe (should be in a subfolder of your lazarus dir)in the project options, make sure you compile with debug info -g or -gwAnd make sure:- you do not strip debug info- you do not use an external debug info file Logged jagorath New member Posts: 34 Re: How to reset gdb settings « Reply #2 on: August 26, 2010, 04:51:56 am » Thanks for the reply Martin_fr, I set the debugger to C:\lazarus\mingw\bin\gdb.exe and the type GDB, and made sure -g was included in the options. The problem remains though - when I run the app it doesn't show up, like gdb can't attach to it or something, and I have to stop the app.I'm using 64-bit lazarus, perhaps GDB only works with 32-bit? « Last Edit: August 26, 2010, 07:02:57 am by jagorath » Logged Martin_fr Administrator Hero Member Posts: 4029 Re: How to reset gdb settings « Reply #3 on: August 26, 2010, 10:43:05 am » gdb should work on 64 bit.no