Skip to content
Snippets Groups Projects
Commit d820338b authored by Simon McVittie's avatar Simon McVittie
Browse files

resolve_link: Tell the compiler how much space we have

parent e3638600
No related branches found
No related tags found
1 merge request!311Build capsule-capture-libs from a bundled copy of libcapsule
......@@ -190,7 +190,7 @@ char *safe_strncpy (char *dest, const char *src, size_t n)
// path each time and return true, until fed a path which is
// not a symlink, at which point it will leave path alone and
// return false:
int resolve_link(const char *prefix, char *path)
int resolve_link(const char *prefix, char path[PATH_MAX])
{
int dfd;
char rl[PATH_MAX];
......
......@@ -17,6 +17,7 @@
#pragma once
#include <limits.h>
#include <stdarg.h>
#include <stddef.h>
#include <stdlib.h>
......@@ -72,7 +73,7 @@ int ptr_list_contains (ptr_list *list, ElfW(Addr) addr);
int ptr_list_add_ptr (ptr_list *list, void *ptr, ptrcmp equals);
char *safe_strncpy (char *dest, const char *src, size_t n);
int resolve_link (const char *prefix, char *path);
int resolve_link (const char *prefix, char path[PATH_MAX]);
int soname_matches_path (const char *soname, const char *path);
size_t build_filename_va (char *buf, size_t len, const char *first_path, va_list ap);
size_t build_filename (char *buf, size_t len, const char *first_path, ...) __attribute__((sentinel));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment