Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. my project crashes and I don't understand why
QtWS25 Last Chance

my project crashes and I don't understand why

Scheduled Pinned Locked Moved Unsolved General and Desktop
6 Posts 5 Posters 238 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    django.Reinhard
    wrote on 23 Mar 2025, 16:25 last edited by
    #1

    Hi,
    I try to write a simple parser, but function crashes at the end.
    I thought to have tracked all mistakes, but obviously I missed some.

    valgrind tells me:

    ==197735==    by 0x10E942: QString::at(long long) const (qstring.h:1234)
    ==197735==    by 0x10DF06: HtmlStreamReader::readNextElement() (htmlstreamreader.cpp:26)
    

    but from my opinion, that line should not fail.

    what am I missing?

    Project can be downloaded

    1 Reply Last reply
    0
    • A Offline
      A Offline
      aha_1980
      Lifetime Qt Champion
      wrote on 23 Mar 2025, 16:34 last edited by
      #2

      @django-Reinhard,

      Run your program in a debugger, it will stop where the crash occurs and you can inspect the stacktrace and the local variables at this point.

      Regards

      Qt has to stay free or it will die.

      1 Reply Last reply
      2
      • D Offline
        D Offline
        Diego Iastrubni
        wrote on 23 Mar 2025, 21:26 last edited by
        #3

        JFYI: your project runs fine on my setup. No crash, and when running under valgrind, no problems found (some minor memory leaks, but no out of bounds).

        I am running debian testing, with Qt 6.8.2. gcc 14.2.0

        1 Reply Last reply
        0
        • D Offline
          D Offline
          django.Reinhard
          wrote on 24 Mar 2025, 03:53 last edited by
          #4

          ... and the winner is: @aha_1980 - for the most stupid response ever.
          debugger crashes at the very beginning, so no chance ...

          @Diego-Iastrubni
          Thank you very much!
          Your reply confirmed my suspicion, that it might be a problem related to stacksize or the like.
          What ever the real cause was, I was able to find a workaround. Thanks a lot for your attention and time!

          J J 2 Replies Last reply 24 Mar 2025, 07:34
          0
          • D django.Reinhard
            24 Mar 2025, 03:53

            ... and the winner is: @aha_1980 - for the most stupid response ever.
            debugger crashes at the very beginning, so no chance ...

            @Diego-Iastrubni
            Thank you very much!
            Your reply confirmed my suspicion, that it might be a problem related to stacksize or the like.
            What ever the real cause was, I was able to find a workaround. Thanks a lot for your attention and time!

            J Offline
            J Offline
            JonB
            wrote on 24 Mar 2025, 07:34 last edited by
            #5

            @django-Reinhard said in my project crashes and I don't understand why:

            ... and the winner is: @aha_1980 - for the most stupid response ever.
            debugger crashes at the very beginning, so no chance ...

            I am glad you have somehow resolved your issue, whatever it was and by whatever means, but @aha_1980's attempt to help and suggestion is not at all "the most stupid response ever", and it's a shame you react to it so impolitely. Running code which "crashes" under a debugger is the first port of call, so often ignored by people posting here, and examining stack/variables can be very useful.

            If your debugger "crashes at the very beginning" that itself is worrying.

            1 Reply Last reply
            3
            • D django.Reinhard
              24 Mar 2025, 03:53

              ... and the winner is: @aha_1980 - for the most stupid response ever.
              debugger crashes at the very beginning, so no chance ...

              @Diego-Iastrubni
              Thank you very much!
              Your reply confirmed my suspicion, that it might be a problem related to stacksize or the like.
              What ever the real cause was, I was able to find a workaround. Thanks a lot for your attention and time!

              J Offline
              J Offline
              jsulm
              Lifetime Qt Champion
              wrote on 24 Mar 2025, 07:45 last edited by
              #6

              @django-Reinhard said in my project crashes and I don't understand why:

              for the most stupid response ever

              Please read and follow https://forum.qt.io/topic/113070/qt-code-of-conduct
              @aha_1980 , like most other people here, is helping voluntarily and writing such responses is not welcome here. You did not even mention that debugger is crashing in your first post...

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              5

              4/6

              24 Mar 2025, 03:53

              • Login

              • Login or register to search.
              4 out of 6
              • First post
                4/6
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved