Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support Qt 6.8 #438

Merged
merged 1 commit into from
Oct 22, 2024
Merged

feat: support Qt 6.8 #438

merged 1 commit into from
Oct 22, 2024

Conversation

justforlxz
Copy link
Member

support qt 6.8

Log:

deepin-ci-robot added a commit to linuxdeepin/dtk6core that referenced this pull request Oct 14, 2024
Synchronize source files from linuxdeepin/dtkcore.

Source-pull-request: linuxdeepin/dtkcore#438
@deepin-ci-robot
Copy link
Contributor

deepin pr auto review

代码审查意见:

  1. 代码风格一致性

    • DDciFileEngineHandler::createDCapFSFileEngineHandler::create函数中,std::unique_ptr和裸指针的使用不一致。建议统一使用std::unique_ptr来管理动态分配的对象,以避免内存泄漏。
  2. 资源管理

    • DDciFileEngineHandler::createDCapFSFileEngineHandler::create函数中,当engine->isValid()返回false时,应该使用std::unique_ptrreset方法来释放资源,而不是手动删除指针。这样可以确保资源管理的统一性和安全性。
  3. 条件编译

    • 使用#if QT_VERSION >= QT_VERSION_CHECK(6, 8, 0)进行条件编译是正确的,但是建议在条件编译块中添加注释,说明为什么需要这个条件编译,以及这个版本变化的具体影响。
  4. 函数命名

    • DDciFileEngineIterator::next函数在Qt 6.8.0及以上版本被重命名为advance,但是函数的实现没有相应地更新。建议更新函数实现,以保持一致性。
  5. 代码重复

    • DDciFileEngineIterator::nextDDciFileEngineIterator::advance函数的实现有重复代码,建议提取公共逻辑到一个单独的函数中,以减少代码重复。
  6. 错误处理

    • DDciFileEngineIterator::hasNextDDciFileEngineIterator::advance函数中,当file为空时,应该抛出异常或者返回一个错误码,而不是继续执行。这样可以避免潜在的空指针解引用问题。
  7. 性能优化

    • DCapFSFileEngine::beginEntryList函数中,DVtableHook::overrideVfptrFun的使用可能会影响性能。如果这个函数调用频繁,建议评估是否有必要使用,或者是否有其他更高效的替代方案。
  8. 安全性

    • DCapFSFileEngine::beginEntryList函数中,DVtableHook::overrideVfptrFun的使用可能会引入安全风险。建议确保这个函数调用的安全性,并且只在必要时使用。

综上所述,建议对代码进行重构,以提高代码质量、性能和安全性。

support qt 6.8

Log:
@deepin-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: justforlxz, kegechen

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

deepin-ci-robot added a commit to linuxdeepin/dtk6core that referenced this pull request Oct 18, 2024
Synchronize source files from linuxdeepin/dtkcore.

Source-pull-request: linuxdeepin/dtkcore#438
@kegechen
Copy link
Contributor

/forcemerge

@deepin-bot
Copy link
Contributor

deepin-bot bot commented Oct 22, 2024

This pr force merged! (status: blocked)

@deepin-bot deepin-bot bot merged commit 2e0b67e into linuxdeepin:master Oct 22, 2024
16 of 21 checks passed
@kegechen kegechen mentioned this pull request Oct 22, 2024
kegechen pushed a commit to linuxdeepin/dtk6core that referenced this pull request Oct 22, 2024
Synchronize source files from linuxdeepin/dtkcore.

Source-pull-request: linuxdeepin/dtkcore#438
kegechen pushed a commit to linuxdeepin/dtk6core that referenced this pull request Oct 22, 2024
Synchronize source files from linuxdeepin/dtkcore.

Source-pull-request: linuxdeepin/dtkcore#438
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants