LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   SIGBUS error (https://www.linuxquestions.org/questions/programming-9/sigbus-error-597244/)

varun_shrivastava 11-05-2007 07:54 AM

SIGBUS error
 
hi
i wrote a gtk application for embedded device, and it was giving SIGBUS error. But i figured out the problem.

Actually i tried to set the size of the window larger than the screen present on embedded device.

So when i commented out that line, the application worked fine.

So my question is: Does setting window size more than the actual size of screen should give SIGBUS error?

Mara 11-06-2007 05:14 PM

SIGBUS is, in many cases an equivalent to SIGSEGV. It means it happens when you write to the memory that is not allocated to your program, for instance. I guess that was just the case (writing to window outside the allocated area for the whole screen).

It should not end with such an error, however. The function you use to draw should notice that the location is out of the available area size and exit with a more 'gentle' error.

Alien_Hominid 11-07-2007 01:04 AM

I don't know how this device operates, but setting your window larger than the screen shouldn't be a problem if you don't work with the screen directly. You should get magnified effect, that's all.


All times are GMT -5. The time now is 06:20 PM.