Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

My application crashed for no reason (0/0 error 0x000000000041B299)



  • Just one minutes ago the application was running fine
    It has connection to CPANEL mysql database , use limereport , smtp

    I got the error in mysql database
    saying "some errors have been detected on the server please look at the bottom of this window in "cpanel"

    Now I deleted the database and recreated it
    This error was not shown
    When I run this application in offline mode (plugging out wifi)
    It runs succesfully although it cannot connect to database

    I guess this is error with database or is it problem with my code??
    16:27:00: The program has unexpectedly finished.
    16:27:00: The process was ended forcefully.
    myapp.exe crashed

    Again if I connect the wifi in middle of running aplication
    The application again crashes

    And now it even crashes while offline

    I got this error once 0x000000000041B299

    It may be my application error,
    What could have caused it???



  • @Thank-You
    Thanks Thanks Thanks to our god
    Brian Crains
    i got the concept from his video
    Oh man
    Really very frustrated because of this thing man
    Thank you guys so much ❤💛💜🧡❤❤❤❤

    It was because of database as well as because of my code

    i fetched datas from database Till that it is fine.
    Now Suppose I use the data without validation (0)
    then it causes this problem

    Like I got 0,0,0,0,0,,0,0 from database
    I wanted to convert it to percentage

    So used 0+0+0+0+0+0+0 = 0
    And
    now converting to percent without seeing
    which results
    = 0/0

    So it crashed my application

    Thank you Thank You



  • Run a debugger. see where it crashes in the code



  • @VRonin
    Yes I found it
    The database is the problem

    In client device it was working properly and now it is not working
    So There can't be code problem

    Do you know about the database problem



  • @Thank-You

    No!!!!
    After seeing couple of hours there is no problem in database

    CAN smtp connection cause this problem??
    I used this code
    https://github.com/xcoder123/SimpleSmtp_SSL_QT5


  • Lifetime Qt Champion

    @Thank-You
    Well all code can crash so yes can be in the SimpleSmtp_SSL_QT5 but
    then the debugger should stop on one of its lines when trying to use it. like sending email.


  • Lifetime Qt Champion

    Hi,

    Are your crash happening only in offline mode ?
    Which version of Qt are you using ?



  • @Thank-You said in My application crashed for no reason:

    I used this code
    https://github.com/xcoder123/SimpleSmtp_SSL_QT5

    That code has not been maintained for 7 years. I'd suggest switching to https://github.com/cutelyst/simple-mail

    CAN smtp connection cause this problem??

    Let the debugger run. when it crashes it will show you what line caused the problem



  • @SGaist
    No sir
    It works fine in offline mode ( Atleast it shows that database is not connected or ......)
    I am using 5.12.8 version of QT

    day before yesterday I compiled the project and gave it to client (version with smtp)
    It was working fine there
    Now , it is not working there too
    And The version without smtp is working fine( it contains database)
    So I am preety sure that database is not the problem

    Although I will try to debug the application
    It would be easier for me if I know what line have caused the error

    0x000000000041B299 I tried searching it but couldn't find any result on this error
    Please see this error
    It says the 0/0 is undefined (which I don't have in code)
    May be database divided by zero Is it the problem??
    https://stackoverflow.com/questions/861778/how-to-avoid-the-divide-by-zero-error-in-sql
    From the errror 0/0 I guess it is. Can you guys think of it??
    Next time I compile it this error is gone and the program crashes



  • @VRonin
    I switched to previous version of my code (it does not have smtp )
    But still the program is crashing?



  • @Thank-You
    Thanks Thanks Thanks to our god
    Brian Crains
    i got the concept from his video
    Oh man
    Really very frustrated because of this thing man
    Thank you guys so much ❤💛💜🧡❤❤❤❤

    It was because of database as well as because of my code

    i fetched datas from database Till that it is fine.
    Now Suppose I use the data without validation (0)
    then it causes this problem

    Like I got 0,0,0,0,0,,0,0 from database
    I wanted to convert it to percentage

    So used 0+0+0+0+0+0+0 = 0
    And
    now converting to percent without seeing
    which results
    = 0/0

    So it crashed my application

    Thank you Thank You


Log in to reply