Conversation
The error messages from utilSetDirGroup() and utilSetGroup() do not include the filename, making it hard to diagnose failures. Add the filename to all four messages. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
The debug flag causes paperman to build with -g instead of -O2, which hides warnings that only appear with optimisation enabled, such as -Wmaybe-uninitialized and -Wclobbered. Remove it so that both paperman and paperman-server build with the same flags. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
The selectAll() override calls itself instead of the parent QSpinBox::selectAll(), causing infinite recursion. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
The selectAll() override calls itself instead of the parent QSpinBox::selectAll(), causing infinite recursion. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Comparing 'this' to NULL is meaningless in well-defined C++ and produces a -Wnonnull-compare warning. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
The poppler-qt5 headers use the deprecated QLinkedList, producing warnings that cannot be fixed in project code. Wrap the include with pragma to suppress -Wdeprecated-declarations. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Mark variables that cross setjmp() as volatile to fix -Wclobbered warnings. Check the return value of fread() and handle failure instead of ignoring it. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Mark the dest parameter as volatile since it crosses a setjmp() boundary. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Initialise variables that the compiler cannot prove are always set before use: len, dest, ch and a2 in add_preview(), rle_encode() and Fax3Encode2DRow() respectively. Drop the bogus assert(this || ptr) which compares this to NULL; just assert(ptr) instead. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
The list parameter is only used inside #ifndef QT_NO_DEBUG, so it is unused in release builds. Add Q_UNUSED() to suppress the warning. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Initialise qgb to nullptr since the default case in the switch does not set it. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Initialise ok to false in both saveImage() overloads since the PNM branch does not set it. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
After the while(ci) loop, ci is always null, so the comparison if(ci == item(0)) can only be true if item(0) is also null, making the ci-> calls inside undefined behaviour. Fix by re-fetching item(0) and null-checking it. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
The qmake-generated Makefile only removes object files on 'clean', leaving the binary behind. Add it to the GNUmakefile clean target. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Add a new TestDirview suite that tests Dirview with a Dirmodel and Dirproxy, using two independent repositories with different directory structures. The tests verify context selection, menu getters, directory expansion with visual-rect visibility checks, and the clicked signal. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Add files alongside the directory structures to make the tests more realistic. This exposes a bug where subdirectory expansion does not work because QFileSystemModel with an empty root path cannot load directory contents below the first level. The subdirectory expansion check is marked as XFAIL until the fix is in place. Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
QFileSystemModel with an empty root path cannot load directory contents below the first level. This means that expanding subdirectories in the dir tree shows nothing. The async loading model is fundamentally incompatible with Dirmodel's virtual-root architecture. Replace the QFileSystemModel inheritance with QAbstractItemModel and synchronous QDir scanning. Introduce a DirNode tree structure that manages the directory hierarchy directly: - Add DirNode struct with lazy population via populateNode() - Scan directories synchronously with QDir on first access - Re-scan on miss in findPath() to handle external changes - Remove waitForLoaded(), createRootIndex(), itemRootIndex() - Remove Diritem's QFileSystemModel dependency (_model, _root) - Add Dirmodel::FilePathRole/FileNameRole enum (same values as QFileSystemModel for compatibility) - Add rmdir(), fileName() methods previously inherited - Update all external references in desktopwidget and dirview Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
make cleanremoves paperman-server and root .o files🤖 Generated with Claude Code