Projects
home:lf14:branches:Mega:23.09
glibc
_service:tar_scm:backport-clang-0027-support-Us...
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:backport-clang-0027-support-Use-CHAR_MAX-as-maximum-value.patch of Package glibc
From d10391ed68bdd2c512f308fdd90c2ffee4795710 Mon Sep 17 00:00:00 2001 From: Adhemerval Zanella <adhemerval.zanella@linaro.org> Date: Tue, 15 Mar 2022 18:01:57 -0300 Subject: [PATCH] support: Use CHAR_MAX as maximum value Instead of -1. --- support/support_process_state.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/support/support_process_state.c b/support/support_process_state.c index dc2296f8dd..a656008034 100644 --- a/support/support_process_state.c +++ b/support/support_process_state.c @@ -59,7 +59,7 @@ support_process_state_wait (pid_t pid, enum support_process_state state) for (;;) { - char cur_state = -1; + char cur_state = CHAR_MAX; while (xgetline (&line, &linesiz, fstatus) > 0) if (strncmp (line, "State:", strlen ("State:")) == 0) { @@ -67,7 +67,7 @@ support_process_state_wait (pid_t pid, enum support_process_state state) break; } /* Fallback to nanosleep for invalid state. */ - if (cur_state == -1) + if (cur_state == CHAR_MAX) break; for (size_t i = 0; i < array_length (process_states); ++i) -- 2.39.3
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2