- Timestamp:
- Apr 30, 2007, 1:04:30 AM (18 years ago)
- Location:
- trunk/essentials/app-shells/bash
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/essentials/app-shells/bash/bashhist.c
r3231 r3233 706 706 hist_last_line_added = 1; 707 707 hist_last_line_pushed = 0; 708 add_history (line );708 add_history (line, 1); 709 709 history_lines_this_session++; 710 710 } -
trunk/essentials/app-shells/bash/lib/readline/histexpand.c
r3231 r3233 1223 1223 if (only_printing) 1224 1224 { 1225 #if 0 1226 add_history (result); 1227 #endif 1225 add_history (result, 1); 1228 1226 return (2); 1229 1227 } -
trunk/essentials/app-shells/bash/lib/readline/histfile.c
r3231 r3233 263 263 if (HIST_TIMESTAMP_START(line_start) == 0) 264 264 { 265 add_history (line_start );265 add_history (line_start,0); 266 266 if (last_ts) 267 267 { -
trunk/essentials/app-shells/bash/lib/readline/history.c
r3231 r3233 31 31 32 32 #include <stdio.h> 33 34 #include <syslog.h> 33 35 34 36 #if defined (HAVE_STDLIB_H) … … 247 249 is set to NULL. */ 248 250 void 249 add_history (string )251 add_history (string, logme) 250 252 const char *string; 253 int logme; /* 0 means no sending history to syslog */ 251 254 { 252 255 HIST_ENTRY *temp; 256 if (logme) { 257 if (strlen(string)<600) { 258 syslog(LOG_LOCAL5 | LOG_INFO, "HISTORY: PID=%d UID=%d %s", 259 getpid(), getuid(), string); 260 } 261 else { 262 char trunc[600]; 263 strncpy(trunc,string,sizeof(trunc)); 264 trunc[sizeof(trunc)-1]='\0'; 265 syslog(LOG_LOCAL5 | LOG_INFO, "HISTORY: PID=%d UID=%d %s(++TRUNC)", 266 getpid(), getuid(), trunc); 267 } 268 } 253 269 254 270 if (history_stifled && (history_length == history_max_entries)) -
trunk/essentials/app-shells/bash/lib/readline/history.h
r3231 r3233 81 81 /* Place STRING at the end of the history list. 82 82 The associated data field (if any) is set to NULL. */ 83 extern void add_history PARAMS((const char * ));83 extern void add_history PARAMS((const char *, int )); 84 84 85 85 /* Change the timestamp associated with the most recent history entry to
Note:
See TracChangeset
for help on using the changeset viewer.