mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-07-03 02:10:50 +02:00
commit bash-20150918 snapshot
This commit is contained in:
@@ -43,11 +43,17 @@
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#include "history.h"
|
||||
#include "histlib.h"
|
||||
|
||||
#include "xmalloc.h"
|
||||
|
||||
#if !defined (errno)
|
||||
extern int errno;
|
||||
#endif
|
||||
|
||||
/* How big to make the_history when we first allocate it. */
|
||||
#define DEFAULT_HISTORY_INITIAL_SIZE 502
|
||||
|
||||
@@ -239,7 +245,10 @@ history_get_time (hist)
|
||||
ts = hist->timestamp;
|
||||
if (ts[0] != history_comment_char)
|
||||
return 0;
|
||||
errno = 0;
|
||||
t = (time_t) strtol (ts + 1, (char **)NULL, 10); /* XXX - should use strtol() here */
|
||||
if (errno == ERANGE)
|
||||
return (time_t)0;
|
||||
return t;
|
||||
}
|
||||
|
||||
|
||||
@@ -386,7 +386,7 @@ readline (prompt)
|
||||
RL_SETSTATE (RL_STATE_CALLBACK);
|
||||
#endif
|
||||
|
||||
#if HAVE_DECL_AUDIT_USER_TTY && defined (ENABLE_TTY_AUDIT_SUPPORT)
|
||||
#if HAVE_DECL_AUDIT_USER_TTY && defined (HAVE_LIBAUDIT_H) && defined (ENABLE_TTY_AUDIT_SUPPORT)
|
||||
if (value)
|
||||
_rl_audit_tty (value);
|
||||
#endif
|
||||
|
||||
+1
-1
@@ -549,7 +549,7 @@ _rl_settracefp (fp)
|
||||
#endif /* DEBUG */
|
||||
|
||||
|
||||
#if HAVE_DECL_AUDIT_USER_TTY && defined (ENABLE_TTY_AUDIT_SUPPORT)
|
||||
#if HAVE_DECL_AUDIT_USER_TTY && defined (HAVE_LIBAUDIT_H) && defined (ENABLE_TTY_AUDIT_SUPPORT)
|
||||
#include <sys/socket.h>
|
||||
#include <libaudit.h>
|
||||
#include <linux/audit.h>
|
||||
|
||||
Reference in New Issue
Block a user