lib/string/: Move string-related files to string/ subdir
Signed-off-by: Alejandro Colomar <alx@kernel.org>
This commit is contained in:
committed by
Serge Hallyn
parent
d1ad64b40f
commit
dbb37b1b31
+12
-12
@@ -134,17 +134,19 @@ libshadow_la_SOURCES = \
|
|||||||
shell.c \
|
shell.c \
|
||||||
sizeof.h \
|
sizeof.h \
|
||||||
spawn.c \
|
spawn.c \
|
||||||
sprintf.c \
|
|
||||||
sprintf.h \
|
|
||||||
sssd.c \
|
sssd.c \
|
||||||
sssd.h \
|
sssd.h \
|
||||||
stpecpy.c \
|
string/sprintf.c \
|
||||||
stpecpy.h \
|
string/sprintf.h \
|
||||||
stpeprintf.c \
|
string/stpecpy.c \
|
||||||
stpeprintf.h \
|
string/stpecpy.h \
|
||||||
strncpy.h \
|
string/stpeprintf.c \
|
||||||
strtcpy.c \
|
string/stpeprintf.h \
|
||||||
strtcpy.h \
|
string/strncpy.h \
|
||||||
|
string/strtcpy.c \
|
||||||
|
string/strtcpy.h \
|
||||||
|
string/zustr2stp.c \
|
||||||
|
string/zustr2stp.h \
|
||||||
strtoday.c \
|
strtoday.c \
|
||||||
sub.c \
|
sub.c \
|
||||||
subordinateio.h \
|
subordinateio.h \
|
||||||
@@ -162,9 +164,7 @@ libshadow_la_SOURCES = \
|
|||||||
xgetgrnam.c \
|
xgetgrnam.c \
|
||||||
xgetgrgid.c \
|
xgetgrgid.c \
|
||||||
xgetspnam.c \
|
xgetspnam.c \
|
||||||
yesno.c \
|
yesno.c
|
||||||
zustr2stp.c \
|
|
||||||
zustr2stp.h
|
|
||||||
|
|
||||||
if WITH_TCB
|
if WITH_TCB
|
||||||
libshadow_la_SOURCES += tcbfuncs.c tcbfuncs.h
|
libshadow_la_SOURCES += tcbfuncs.c tcbfuncs.h
|
||||||
|
|||||||
+1
-1
@@ -13,7 +13,7 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include "getdef.h"
|
#include "getdef.h"
|
||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -36,7 +36,7 @@
|
|||||||
#include <attr/libattr.h>
|
#include <attr/libattr.h>
|
||||||
#endif /* WITH_ATTR */
|
#endif /* WITH_ATTR */
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
static /*@null@*/const char *src_orig;
|
static /*@null@*/const char *src_orig;
|
||||||
|
|||||||
+1
-1
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
#include "defines.h"
|
#include "defines.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
+1
-1
@@ -19,7 +19,7 @@
|
|||||||
#include "failure.h"
|
#include "failure.h"
|
||||||
#include "memzero.h"
|
#include "memzero.h"
|
||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
|
|
||||||
#define YEAR (365L*DAY)
|
#define YEAR (365L*DAY)
|
||||||
|
|||||||
+1
-1
@@ -25,7 +25,7 @@
|
|||||||
#include "alloc.h"
|
#include "alloc.h"
|
||||||
#include "getdef.h"
|
#include "getdef.h"
|
||||||
#include "shadowlog_internal.h"
|
#include "shadowlog_internal.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
+1
-1
@@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
#include "alloc.h"
|
#include "alloc.h"
|
||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
#include "stpeprintf.h"
|
#include "string/stpeprintf.h"
|
||||||
#include "idmapping.h"
|
#include "idmapping.h"
|
||||||
#if HAVE_SYS_CAPABILITY_H
|
#if HAVE_SYS_CAPABILITY_H
|
||||||
#include <sys/prctl.h>
|
#include <sys/prctl.h>
|
||||||
|
|||||||
@@ -19,8 +19,8 @@
|
|||||||
#include <lastlog.h>
|
#include <lastlog.h>
|
||||||
#include "memzero.h"
|
#include "memzero.h"
|
||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
#include "strncpy.h"
|
#include "string/strncpy.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
+1
-1
@@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
#include "alloc.h"
|
#include "alloc.h"
|
||||||
#include "getdef.h"
|
#include "getdef.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -28,7 +28,7 @@
|
|||||||
#endif /* ENABLE_SUBIDS */
|
#endif /* ENABLE_SUBIDS */
|
||||||
#include "getdef.h"
|
#include "getdef.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
static char *passwd_db_file = NULL;
|
static char *passwd_db_file = NULL;
|
||||||
|
|||||||
+1
-1
@@ -27,7 +27,7 @@
|
|||||||
#include <pwd.h>
|
#include <pwd.h>
|
||||||
#include "getdef.h"
|
#include "getdef.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
#ifndef USE_PAM
|
#ifndef USE_PAM
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
#include "stpecpy.h"
|
#include "string/stpecpy.h"
|
||||||
|
|
||||||
|
|
||||||
extern inline char *stpecpy(char *dst, char *end, const char *restrict src);
|
extern inline char *stpecpy(char *dst, char *end, const char *restrict src);
|
||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
#include "stpeprintf.h"
|
#include "string/stpeprintf.h"
|
||||||
|
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
|
|
||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
|
|
||||||
extern inline ssize_t strtcpy(char *restrict dst, const char *restrict src,
|
extern inline ssize_t strtcpy(char *restrict dst, const char *restrict src,
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
#include "zustr2stp.h"
|
#include "string/zustr2stp.h"
|
||||||
|
|
||||||
|
|
||||||
extern inline char *zustr2stp(char *restrict dst, const char *restrict src,
|
extern inline char *zustr2stp(char *restrict dst, const char *restrict src,
|
||||||
+3
-3
@@ -24,9 +24,9 @@
|
|||||||
|
|
||||||
#include "alloc.h"
|
#include "alloc.h"
|
||||||
#include "sizeof.h"
|
#include "sizeof.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strncpy.h"
|
||||||
#include "strncpy.h"
|
#include "string/strtcpy.h"
|
||||||
#include "zustr2stp.h"
|
#include "string/zustr2stp.h"
|
||||||
|
|
||||||
#ident "$Id$"
|
#ident "$Id$"
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -33,7 +33,7 @@
|
|||||||
#include "pwio.h"
|
#include "pwio.h"
|
||||||
#include "shadowio.h"
|
#include "shadowio.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
#ifdef WITH_TCB
|
#ifdef WITH_TCB
|
||||||
#include "tcbfuncs.h"
|
#include "tcbfuncs.h"
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
+1
-1
@@ -32,7 +32,7 @@
|
|||||||
/*@-exitarg@*/
|
/*@-exitarg@*/
|
||||||
#include "exitcodes.h"
|
#include "exitcodes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Global variables.
|
* Global variables.
|
||||||
|
|||||||
+1
-1
@@ -31,7 +31,7 @@
|
|||||||
/*@-exitarg@*/
|
/*@-exitarg@*/
|
||||||
#include "exitcodes.h"
|
#include "exitcodes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
#ifndef SHELLS_FILE
|
#ifndef SHELLS_FILE
|
||||||
#define SHELLS_FILE "/etc/shells"
|
#define SHELLS_FILE "/etc/shells"
|
||||||
|
|||||||
+1
-1
@@ -35,7 +35,7 @@
|
|||||||
/*@-exitarg@*/
|
/*@-exitarg@*/
|
||||||
#include "exitcodes.h"
|
#include "exitcodes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Global variables
|
* Global variables
|
||||||
|
|||||||
+2
-2
@@ -38,8 +38,8 @@
|
|||||||
#include "sgroupio.h"
|
#include "sgroupio.h"
|
||||||
#endif
|
#endif
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "stpecpy.h"
|
#include "string/stpecpy.h"
|
||||||
#include "stpeprintf.h"
|
#include "string/stpeprintf.h"
|
||||||
/*
|
/*
|
||||||
* exit status values
|
* exit status values
|
||||||
*/
|
*/
|
||||||
|
|||||||
+1
-1
@@ -37,7 +37,7 @@
|
|||||||
/*@-exitarg@*/
|
/*@-exitarg@*/
|
||||||
#include "exitcodes.h"
|
#include "exitcodes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
#ifdef USE_PAM
|
#ifdef USE_PAM
|
||||||
#include "pam_defs.h"
|
#include "pam_defs.h"
|
||||||
|
|||||||
+1
-1
@@ -20,7 +20,7 @@
|
|||||||
#include "prototypes.h"
|
#include "prototypes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sizeof.h"
|
#include "sizeof.h"
|
||||||
#include "zustr2stp.h"
|
#include "string/zustr2stp.h"
|
||||||
/*
|
/*
|
||||||
* Global variables
|
* Global variables
|
||||||
*/
|
*/
|
||||||
|
|||||||
+1
-1
@@ -32,7 +32,7 @@
|
|||||||
#include "pwio.h"
|
#include "pwio.h"
|
||||||
#include "shadowio.h"
|
#include "shadowio.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* exit status values
|
* exit status values
|
||||||
|
|||||||
@@ -58,7 +58,7 @@
|
|||||||
/*@-exitarg@*/
|
/*@-exitarg@*/
|
||||||
#include "exitcodes.h"
|
#include "exitcodes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Global variables
|
* Global variables
|
||||||
|
|||||||
+1
-1
@@ -27,7 +27,7 @@
|
|||||||
/*@-exitarg@*/
|
/*@-exitarg@*/
|
||||||
#include "exitcodes.h"
|
#include "exitcodes.h"
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Global variables
|
* Global variables
|
||||||
|
|||||||
+1
-1
@@ -63,7 +63,7 @@
|
|||||||
#include "tcbfuncs.h"
|
#include "tcbfuncs.h"
|
||||||
#endif
|
#endif
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
#ifndef SKEL_DIR
|
#ifndef SKEL_DIR
|
||||||
|
|||||||
+1
-1
@@ -52,7 +52,7 @@
|
|||||||
#include "subordinateio.h"
|
#include "subordinateio.h"
|
||||||
#endif /* ENABLE_SUBIDS */
|
#endif /* ENABLE_SUBIDS */
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
+1
-1
@@ -58,7 +58,7 @@
|
|||||||
#include "tcbfuncs.h"
|
#include "tcbfuncs.h"
|
||||||
#endif
|
#endif
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
+1
-1
@@ -44,7 +44,7 @@
|
|||||||
#include "tcbfuncs.h"
|
#include "tcbfuncs.h"
|
||||||
#endif /* WITH_TCB */
|
#endif /* WITH_TCB */
|
||||||
#include "shadowlog.h"
|
#include "shadowlog.h"
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
#define MSG_WARN_EDIT_OTHER_FILE _( \
|
#define MSG_WARN_EDIT_OTHER_FILE _( \
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ test_strncpy_LDADD = \
|
|||||||
$(NULL)
|
$(NULL)
|
||||||
|
|
||||||
test_strtcpy_SOURCES = \
|
test_strtcpy_SOURCES = \
|
||||||
../../lib/strtcpy.c \
|
../../lib/string/strtcpy.c \
|
||||||
test_strtcpy.c \
|
test_strtcpy.c \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
test_strtcpy_CFLAGS = \
|
test_strtcpy_CFLAGS = \
|
||||||
@@ -73,7 +73,7 @@ test_strtcpy_LDADD = \
|
|||||||
$(NULL)
|
$(NULL)
|
||||||
|
|
||||||
test_xasprintf_SOURCES = \
|
test_xasprintf_SOURCES = \
|
||||||
../../lib/sprintf.c \
|
../../lib/string/sprintf.c \
|
||||||
test_xasprintf.c \
|
test_xasprintf.c \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
test_xasprintf_CFLAGS = \
|
test_xasprintf_CFLAGS = \
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
#include <cmocka.h>
|
#include <cmocka.h>
|
||||||
|
|
||||||
#include "sizeof.h"
|
#include "sizeof.h"
|
||||||
#include "strncpy.h"
|
#include "string/strncpy.h"
|
||||||
|
|
||||||
|
|
||||||
static void test_STRNCPY_trunc(void **state);
|
static void test_STRNCPY_trunc(void **state);
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
#include <cmocka.h>
|
#include <cmocka.h>
|
||||||
|
|
||||||
#include "sizeof.h"
|
#include "sizeof.h"
|
||||||
#include "strtcpy.h"
|
#include "string/strtcpy.h"
|
||||||
|
|
||||||
|
|
||||||
static void test_STRTCPY_trunc(void **state);
|
static void test_STRTCPY_trunc(void **state);
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
#include <stdint.h> // Required by <cmocka.h>
|
#include <stdint.h> // Required by <cmocka.h>
|
||||||
#include <cmocka.h>
|
#include <cmocka.h>
|
||||||
|
|
||||||
#include "sprintf.h"
|
#include "string/sprintf.h"
|
||||||
|
|
||||||
|
|
||||||
#define assert_unreachable() assert_true(0)
|
#define assert_unreachable() assert_true(0)
|
||||||
|
|||||||
Reference in New Issue
Block a user