pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pkg/59096: qt6 apps with qt6-qtbase don't work on NetBSD/earmv7hf10.1



The following reply was made to PR pkg/59096; it has been noted by GNATS.

From: Izumi Tsutsui <tsutsui%ceres.dti.ne.jp@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc: tsutsui%ceres.dti.ne.jp@localhost
Subject: Re: pkg/59096: qt6 apps with qt6-qtbase don't work on NetBSD/earmv7hf10.1
Date: Mon, 8 Sep 2025 23:12:59 +0900

 The following minimum diff also works.
 (not sure what "offset is aligned, this can't overflow" comments meant)
 
 ```
 $NetBSD$
 
 - fix wrong alignment calculations that could fail on NetBSD/earmv7hf
   where n_descsz==9
   
 --- src/corelib/plugin/qelfparser_p.cpp.orig	2024-10-01 10:46:30.000000000 +0000
 +++ src/corelib/plugin/qelfparser_p.cpp
 @@ -619,12 +619,12 @@ static QLibraryScanResult scanProgramHea
              // overflow check: calculate where the next note will be, if it exists
              T::Off next_offset = offset;
              next_offset += sizeof(T::Nhdr);          // can't overflow (we checked above)
 -            next_offset += NoteAlignment - 3;        // offset is aligned, this can't overflow
 +            next_offset += NoteAlignment - 1;        // offset is aligned, this can't overflow
              if (qAddOverflow<T::Off>(next_offset, n_namesz, &next_offset))
                  break;
              next_offset &= -NoteAlignment;
  
 -            next_offset += NoteAlignment - 3;        // offset is aligned, this can't overflow
 +            next_offset += NoteAlignment - 1;        // offset is aligned, this can't overflow
              if (qAddOverflow<T::Off>(next_offset, n_descsz, &next_offset))
                  break;
              next_offset &= -NoteAlignment;
 
 ```
 
 ---
 Izumi Tsutsui
 


Home | Main Index | Thread Index | Old Index