* ``-m 0'' turns off -- MARK -- now. (closes: Bug#28629, Bug#31494)

* Changed Greg's e-mail address to represent his current one.
  * Shortened line length for kernel logging slightly.
  * Corrected return value of AddModule (closes: Bug#30093)
  * Finally fixed an error with `-a' processing, thanks to Topi Miettinen
    <tom@medialab.sonera.net> (closes: Bug#30462)
This commit is contained in:
Joey Schulze 1999-01-19 00:09:12 +00:00
parent 7d36dc9402
commit 68b50092c7
8 changed files with 41 additions and 20 deletions

View File

@ -59,4 +59,4 @@ contributions from the entire community.
Dr. Greg Wettstein
Oncology Research Division Computing Facility
Roger Maris Cancer Center
greg@wind.rmcc.com
greg@wind.enjellic.com

View File

@ -53,7 +53,7 @@ Dr. Wettstein
Oncology Research Division Computing Facility
Roger Maris Cancer Center
Fargo, ND
greg@wind.rmcc.com
greg@wind.enjellic.com
Stephen Tweedie
Department of Computer Science

View File

@ -409,7 +409,7 @@ made major improvements.
.PD 0
.TP
Dr. Greg Wettstein (greg@wind.rmcc.com)
Dr. Greg Wettstein (greg@wind.enjellic.com)
.TP
Enjellic Systems Development
.PD

View File

@ -208,6 +208,11 @@
*
* Mon Oct 12 13:01:27 MET DST 1998: Martin Schulze <joey@infodrom.north.de>
* Used unsigned long and strtoul() to resolve kernel oops symbols.
*
* Sun Jan 3 18:38:03 CET 1999: Martin Schulze <joey@infodrom.north.de>
* Shortened LOG_LINE_LENGTH in order to get long lines splitted
* up earlier and syslogd has a better chance concatenating them
* together again.
*/
@ -241,7 +246,7 @@ _syscall3(int,ksyslog,int, type, char *, buf, int, len);
#endif
#define LOG_BUFFER_SIZE 4096
#define LOG_LINE_LENGTH 1024
#define LOG_LINE_LENGTH 1000
#ifndef TESTING
#if defined(FSSTND)
@ -876,7 +881,7 @@ static void LogProcLine(void)
* from the message pseudo-file into this fresh buffer.
*/
memset(log_buffer, '\0', sizeof(log_buffer));
if ( (rdcnt = read(kmsg, log_buffer, sizeof(log_buffer))) < 0 )
if ( (rdcnt = read(kmsg, log_buffer, sizeof(log_buffer)-1)) < 0 )
{
if ( errno == EINTR )
return;

View File

@ -70,6 +70,11 @@
* forgotton in <unistd.h> from glibc. Added more log
* information if problems occurred while reading a system map
* file, by submission from Mark Simon Phillips <M.S.Phillips@nortel.co.uk>.
*
* Sun Jan 3 18:38:03 CET 1999: Martin Schulze <joey@infodrom.north.de>
* Corrected return value of AddModule if /dev/kmem can't be
* loaded. This will prevent klogd from segfaulting if /dev/kmem
* is not available. Patch from Topi Miettinen <tom@medialab.sonera.net>.
*/
@ -393,7 +398,7 @@ static int AddModule(address, symbol)
if ( (memfd = open("/dev/kmem", O_RDONLY)) < 0 )
{
Syslog(LOG_WARNING, "Error opening /dev/kmem\n");
return(1);
return(0);
}
if ( llseek(memfd, address, SEEK_SET) < 0 )
{

View File

@ -113,8 +113,11 @@ and not the fqdn. Multiple hosts may be specified using the colon
The
.B syslogd
logs a mark timestamp regularly. The default
\fIinterval\fR between two \fI-- MARK --\fR lines is 20 minutes. This
can be changed with this option.
.I interval
between two \fI-- MARK --\fR lines is 20 minutes. This can be changed
with this option. Setting the
.I interval
to zero turns it off entirely.
.TP
.B "\-n"
Avoid auto-backgrounding. This is needed especially if the
@ -548,7 +551,7 @@ passwords.
.LP
.SH COLLABORATORS
.B Syslogd
is taken from BSD sources, Greg Wettstein (greg@wind.rmcc.com)
is taken from BSD sources, Greg Wettstein (greg@wind.enjellic.com)
performed the port to Linux, Martin Schulze (joey@linux.de)
fixed some bugs and added several new features.
.B Klogd
@ -567,7 +570,7 @@ Roger Maris Cancer Center
.TP
Fargo, ND
.TP
greg@wind.rmcc.com
greg@wind.enjellic.com
.TP
Stephen Tweedie

View File

@ -392,6 +392,6 @@ higher.
.SH AUTHORS
The
.B syslogd
is taken from BSD sources, Greg Wettstein (greg@wind.rmcc.com)
is taken from BSD sources, Greg Wettstein (greg@wind.enjellic.com)
performed the port to Linux, Martin Schulze (joey@linux.de)
made some bugfixes and added some new features.

View File

@ -404,6 +404,13 @@ static char sccsid[] = "@(#)syslogd.c 5.27 (Berkeley) 10/10/88";
* Mon Oct 12 22:18:34 CEST 1998: Martin Schulze <joey@infodrom.north.de>
* Modified printline() to support 8bit characters - such as
* russion letters. Thanks to Vladas Lapinskas <lapinskas@mail.iae.lt>.
*
* Sat Nov 14 02:29:37 CET 1998: Martin Schulze <joey@infodrom.north.de>
* ``-m 0'' now turns of MARK logging entirely.
*
* Tue Jan 19 01:04:18 MET 1999: Martin Schulze <joey@infodrom.north.de>
* Finally fixed an error with `-a' processing, thanks to Topi
* Miettinen <tom@medialab.sonera.net>.
*/
@ -453,7 +460,7 @@ static char sccsid[] = "@(#)syslogd.c 5.27 (Berkeley) 10/10/88";
#include <syscall.h>
#include <arpa/nameser.h>
#include <arpa/inet.h>
#include <resolv.h>
p#include <resolv.h>
#ifndef TESTING
#include "pidfile.h"
#endif
@ -555,7 +562,6 @@ int funix[MAXFUNIX] = { -1, };
* This table contains plain text for h_errno errors used by the
* net subsystem.
*/
const char *sys_h_errlist[] = {
"No problem", /* NETDB_SUCCESS */
"Authoritative answer: host not found", /* HOST_NOT_FOUND */
"Non-authoritative answer: host not found, or serverfail", /* TRY_AGAIN */
@ -754,12 +760,12 @@ int main(argc, argv)
int num_fds;
#endif /* __GLIBC__ */
/*
* It took me quite some time to figure out so I guess I
* should better write it down. unixm is a list of file
* descriptors from which one can read(). This is contrary to
* readfds which is a list of file descriptors where activity
* is monitored by select() and from which one cannot read().
* -Joey
* It took me quite some time to figure out how this is
* supposed to work so I guess I should better write it down.
* unixm is a list of file descriptors from which one can
* read(). This is in contrary to readfds which is a list of
* file descriptors where activity is monitored by select()
* and from which one cannot read(). -Joey
*/
fd_set unixm, readfds;
@ -785,7 +791,7 @@ int main(argc, argv)
#ifndef TESTING
chdir ("/");
#endif
for (i = 1; i < nfunix; i++) {
for (i = 1; i < MAXFUNIX; i++) {
funixn[i] = "";
funix[i] = -1;
}
@ -2058,6 +2064,7 @@ void domark()
int lognum;
#endif
if (MarkInterval > 0) {
now = time(0);
MarkSeq += TIMERINTVL;
if (MarkSeq >= MarkInterval) {
@ -2079,6 +2086,7 @@ void domark()
BACKOFF(f);
}
}
}
(void) signal(SIGALRM, domark);
(void) alarm(TIMERINTVL);
}