Skip to content

Commit 31addff

Browse files
committed
Fix warning of debuild
1 parent a86ed49 commit 31addff

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/recipe/os/APT/Debian.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* |
99
* Created On : <2023-09-02>
1010
* Major Revision : 3
11-
* Last Modified : <2025-03-25>
11+
* Last Modified : <2025-06-16>
1212
* ------------------------------------------------------------*/
1313

1414
static SourceProvider_t os_debian_upstream =
@@ -127,7 +127,9 @@ os_debian_setsrc (char *option)
127127
if (use_cdrom)
128128
{
129129
chsrc_backup (OS_Debian_old_SourceList);
130-
system ("rm " OS_Debian_old_SourceList);
130+
int rm_status = system ("rm " OS_Debian_old_SourceList);
131+
if (rm_status != 0) { /* Placate -Wunused-result */ }
132+
131133
chsrc_warn2 ("旧版源配置文件中使用了 CDROM 源,已删除(但备份)该配置文件,重新配置");
132134
/* 现在的情况是:系统中已经没有配置文件了 */
133135
sourcelist_exist = ensure_debian_or_ubuntu_old_sourcelist (OS_Is_Debian_Literally);

src/recipe/ware/Homebrew.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* Contributors : Nil Null <[email protected]>
66
* Created On : <2023-09-10>
77
* Major Revision : 3
8-
* Last Modified : <2024-08-28>
8+
* Last Modified : <2025-06-16>
99
* ------------------------------------------------------------*/
1010

1111
/**
@@ -33,7 +33,8 @@ wr_homebrew_getsrc (char *option)
3333
"echo HOMEBREW_BOTTLE_DOMAIN=$HOMEBREW_BOTTLE_DOMAIN;"
3434
"echo HOMEBREW_BREW_GIT_REMOTE=$HOMEBREW_BREW_GIT_REMOTE;"
3535
"echo HOMEBREW_CORE_GIT_REMOTE=$HOMEBREW_CORE_GIT_REMOTE;";
36-
system (cmd);
36+
int status = system (cmd);
37+
if (status != 0) { /* NOOP */ }
3738
}
3839

3940
/**

0 commit comments

Comments
 (0)