Rename procutils_read_file to __libc_procutils_read_file [BZ #31755]

Fix BZ #31755 by renaming the internal function procutils_read_file to
__libc_procutils_read_file.

Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
This commit is contained in:
H.J. Lu 2024-05-19 18:46:36 -07:00
parent 4e21cb95e2
commit 7935e7a537
3 changed files with 7 additions and 5 deletions

View File

@ -105,7 +105,7 @@ pidfd_getpid (int fd)
*_fitoa_word (fd, p, 10, 0) = '\0';
struct parse_fdinfo_t fdinfo = { .found = false, .pid = -1 };
if (!procutils_read_file (fdinfoname, parse_fdinfo, &fdinfo))
if (!__libc_procutils_read_file (fdinfoname, parse_fdinfo, &fdinfo))
/* The fdinfo contains an invalid 'Pid:' value. */
return INLINE_SYSCALL_ERROR_RETURN_VALUE (EBADF);

View File

@ -71,8 +71,9 @@ next_line (char **r, int fd, char *const buffer, char **cp, char **re,
}
bool
procutils_read_file (const char *filename, procutils_closure_t closure,
void *arg)
__libc_procutils_read_file (const char *filename,
procutils_closure_t closure,
void *arg)
{
enum { buffer_size = PROCUTILS_MAX_LINE_LEN };
char buffer[buffer_size];

View File

@ -37,7 +37,8 @@ typedef int (*procutils_closure_t) (const char *line, void *arg);
It returns true in case the file is fully read or false if CLOSURE
returns a value diferent than 0. */
bool procutils_read_file (const char *filename, procutils_closure_t closure,
void *arg) attribute_hidden;
bool __libc_procutils_read_file (const char *filename,
procutils_closure_t closure,
void *arg) attribute_hidden;
#endif