Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Bus Error (core dumped)

Options
  • 30-08-2000 6:04pm
    #1
    Closed Accounts Posts: 14


    Does anyone know what causes this run time error: Bus Error ? I ran the program through a debugger and found that it bombed out on a function call (not while executing the function). The os is solaris. My thoughts are that the crash was due stack overflow or memory leaks.
    Any help would be great!

    doon.


Comments

  • Registered Users Posts: 3,744 ✭✭✭deRanged


    that's usually a pointer error.
    can you use the debugger to check the values of your variables?
    that should tell you if any of them are null.


  • Closed Accounts Posts: 14 doon


    cheers.


  • Closed Accounts Posts: 251 ✭✭UNIFLU


    deRanged,
    yOU tHINK tHAT iTS tRYING tO pASS nULL vALUES ?


  • Closed Accounts Posts: 251 ✭✭UNIFLU


    deRanged,
    yOU tHINK tHAT iTS tRYING tO pASS nULL vALUES ?


  • Registered Users Posts: 3,744 ✭✭✭deRanged


    yeah I do.
    or referencing outside array bounds or somesuch.


  • Advertisement
  • Registered Users Posts: 310 ✭✭Cerberus


    Does a pointer error not usually give the error segmentation fault: Core dumped
    Or is this the same as a bus error?


  • Moderators, Social & Fun Moderators Posts: 10,501 Mod ✭✭✭✭ecksor


    A segmentation fault is detected by the operating system, while a bus error is detected by your hardware, altho both are caused by bad pointers.

    A segmentation fault is when your program tries to access memory that is on a segment of memory that is not it's own, and this is caught and kicked out by the operating system. However, under some circumstances, a bad pointer can point to somewhere that is valid as far as the OS is concerned, but will make garbage out of your stack or your executable, causing garbage to try and be executed, which is usually caught by the hardware in your machine. Then you get a bus error.


  • Registered Users Posts: 310 ✭✭Cerberus


    X_OR
    I hope you're not in my class cos if you are then none of the rest of us are going to be able to get jobs. biggrin.gif

    [This message has been edited by Cerberus (edited 01-09-2000).]


  • Moderators, Social & Fun Moderators Posts: 10,501 Mod ✭✭✭✭ecksor


    I dropped out wink.gif


Advertisement