mirror of
https://github.com/curl/curl.git
synced 2026-07-23 16:17:21 +03:00
Check for basename() is now done the same as other function checks
This commit is contained in:
parent
86cec97b22
commit
6d4e6cc813
7 changed files with 127 additions and 32 deletions
|
|
@ -31,6 +31,12 @@
|
|||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
|
||||
#if defined(MSDOS) || defined(WIN32)
|
||||
# if defined(HAVE_LIBGEN_H) && defined(HAVE_BASENAME)
|
||||
# include <libgen.h>
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#include <curl/curl.h>
|
||||
|
||||
#include "urlglob.h"
|
||||
|
|
@ -5437,7 +5443,7 @@ static int create_dir_hierarchy(const char *outfile, FILE *errors)
|
|||
/* basename() returns a pointer to the last component of a pathname.
|
||||
* Ripped from lib/formdata.c.
|
||||
*/
|
||||
static char *basename(char *path)
|
||||
static char *Curl_basename(char *path)
|
||||
{
|
||||
/* Ignore all the details above for now and make a quick and simple
|
||||
implementaion here */
|
||||
|
|
@ -5457,6 +5463,7 @@ static char *basename(char *path)
|
|||
|
||||
return path;
|
||||
}
|
||||
#define basename(x) Curl_basename((x))
|
||||
#endif /* HAVE_BASENAME */
|
||||
|
||||
/* The following functions are taken with modification from the DJGPP
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue