Skip to content

chore: update changelog to 2.0.25#212

Merged
Ivy233 merged 1 commit into
linuxdeepin:masterfrom
mhduiy:dev-changelog-2.0.25
Jun 4, 2026
Merged

chore: update changelog to 2.0.25#212
Ivy233 merged 1 commit into
linuxdeepin:masterfrom
mhduiy:dev-changelog-2.0.25

Conversation

@mhduiy

@mhduiy mhduiy commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

更新说明

自动更新 changelog 到版本 2.0.25

变更内容

  • 更新 debian/changelog

版本信息

  • 新版本: 2.0.25
  • 目标分支: master

Summary by Sourcery

Chores:

  • Refresh debian/changelog entries to reflect version 2.0.25 targeting master.

@sourcery-ai

sourcery-ai Bot commented Jun 4, 2026

Copy link
Copy Markdown
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Updates the Debian changelog to bump the project version to 2.0.25 targeting the master branch.

File-Level Changes

Change Details Files
Bump package version and metadata in Debian changelog to 2.0.25.
  • Add a new 2.0.25 entry at the top of the changelog (or update existing top entry) to reflect the new release.
  • Ensure the changelog formatting follows Debian policy (version line, distribution, urgency, maintainer signature, and timestamp).
  • Set the target branch/version information to align with the master branch release.
debian/changelog

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown

TAG Bot

TAG: 2.0.25
EXISTED: no
DISTRIBUTION: unstable

update changelog to 2.0.25

Log: update changelog to 2.0.25
@mhduiy mhduiy force-pushed the dev-changelog-2.0.25 branch from 18fd830 to e1f6ddc Compare June 4, 2026 12:08
@deepin-ci-robot

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Ivy233, mhduiy

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

Details 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

@Ivy233 Ivy233 merged commit f832510 into linuxdeepin:master Jun 4, 2026
16 of 19 checks passed
@deepin-ci-robot

Copy link
Copy Markdown

deepin pr auto review

你好!我是CodeGeeX。我已仔细审查了你提供的 Git Diff 输入。

从本次提交的 debian/changelog 来看,本次修改主要包含两个核心改动:

  1. 修复线程安全:修复 FIFO 管道处理程序中的线程安全问题。
  2. 代码重构:移除 Dconf 工具类和死代码。

虽然 Diff 内容仅包含变更日志,但基于变更日志中暴露出的修改意图,我可以为你提供针对这两项改动的深度代码审查意见。当你或你的团队在编写/审查实际的 C++/C 代码时,请务必关注以下几个维度的潜在问题:

一、 语法与逻辑

1. FIFO 管道的读写逻辑与阻塞问题

  • 审查点:FIFO(命名管道)默认是阻塞的。如果在多线程环境下,一个线程正在 read()open() FIFO,而另一个线程试图修改共享状态或关闭 FIFO,极易产生死锁或竞态条件。
  • 改进建议:确保打开 FIFO 时使用了 O_NONBLOCKO_RDWR | O_NONBLOCK 标志,避免线程无限期挂起。如果必须使用阻塞模式,请确保在退出或取消时,能通过发送特定信号或关闭管道的另一端来优雅地唤醒阻塞线程。

2. 状态同步逻辑

  • 审查点:修复线程安全通常意味着引入锁(如 std::mutex)。如果逻辑中存在“先检查后执行”的代码,例如 if (!fifo_eof) { read_fifo(); },仅仅加锁是不够的,必须使用条件变量(std::condition_variable)或在锁的保护下检查状态,防止虚假唤醒和竞态。

二、 代码质量

1. 移除 Dconf 工具类后的依赖清理

  • 审查点:移除 Dconf 工具类后,项目的 CMakeLists.txtMakefile.am 中是否还残留了对 dconf 库的链接依赖(如 -ldconf)?相关的头文件引用(#include <dconf/dconf.h>)是否在所有文件中被彻底清理?
  • 改进建议:使用 IDE 的全局搜索功能确认没有遗漏的 Dconf 引用,并在构建脚本中移除相关链接指令,保持构建配置的整洁。

2. 死代码的彻底清除

  • 审查点:死代码不仅指未调用的函数,还包括仅被这些函数使用的私有成员变量、全局常量、甚至是特定的宏定义。
  • 改进建议:借助编译器的 -Wunused-function-Wunused-variable 等警告选项,或者使用静态分析工具(如 cppcheckclang-tidy)来确认所有不可达代码和未使用依赖已被完全清除。

三、 代码性能

1. 锁的粒度与性能损耗

  • 审查点:修复 FIFO 线程安全时,如果使用了互斥锁,需警惕“粗粒度锁”。例如,是否在 while(is_running) 的循环外层直接加锁,导致其他线程无法访问共享资源?
  • 改进建议:将临界区(加锁范围)缩小到仅保护共享数据的最小代码段。对于 FIFO 的读写缓冲区,考虑使用无锁队列生产者-消费者模型,这能显著降低线程上下文切换和锁争用的开销。

2. I/O 轮询开销

  • 审查点:如果 FIFO 的读取逻辑采用了非阻塞轮询(如 while(true) { read(...); sleep(1); }),这会带来不必要的 CPU 空转和延迟。
  • 改进建议:使用更高效的 I/O 多路复用机制,如 epoll (Linux) 或 select / poll,配合事件驱动,当 FIFO 有数据时才唤醒线程处理,既降低 CPU 占用,又提高响应速度。

四、 代码安全

1. FIFO 管道的本地提权与符号链接攻击

  • 审查点:FIFO 作为文件系统中的实体,存在被恶意替换的风险。如果攻击者在程序启动前创建了同名的 FIFO 或符号链接,可能会诱使 dde-session(作为会话管理器,权限较高)向攻击者控制的文件写入敏感数据,或读取恶意构造的数据。
  • 改进建议
    • 创建 FIFO 时,使用 mkfifo() 并严格设置权限(如 0600),确保仅当前用户可读写。
    • 打开 FIFO 前,使用 lstat() 检查是否为符号链接,防止符号链接攻击。
    • 最好将 FIFO 创建在受保护的安全目录下(如 /run/user/<UID>/),该目录由 systemd/pam 自动创建且仅属主可访问。

2. 缓冲区溢出风险

  • 审查点:从 FIFO 读取数据到缓冲区时,是否对读取的长度进行了严格校验?
  • 改进建议:如果使用 C 风格的 read(fd, buffer, size),必须确保 size 不超过 buffer 实际分配的内存大小;如果拼接字符串,需防范因缺乏结尾 \0 导致的越界读取。推荐使用安全的容器(如 std::vector<char>)并严格限制单次读取的长度。

总结
本次变更的核心在于并发安全代码瘦身。在审查实际的代码实现时,请重点确认:FIFO 的阻塞/非阻塞机制是否合理、锁的粒度是否足够小、FIFO 文件的权限与路径是否安全,以及 Dconf 相关的构建依赖是否被彻底剥离。

如果你能提供具体的 .cpp.h 文件的 Git Diff,我可以为你提供更精准的代码行级别的审查和修改建议!

@deepin-bot

deepin-bot Bot commented Jun 4, 2026

Copy link
Copy Markdown

TAG Bot

Tag created successfully

📋 Tag Details
  • Tag Name: 2.0.25
  • Tag SHA: 439041f21033dec58c6cdd1fdab6f1049ecac8c9
  • Commit SHA: f832510019102397a8b31cc198a38364c2774f0c
  • Tag Message:
    Release dde-session 2.0.25
    
    
  • Tagger:
    • Name: mhduiy
  • Distribution: unstable

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