Mercurial > emacs
changeset 4064:d14ba65a1363
*** empty log message ***
author | David J. MacKenzie <djm@gnu.org> |
---|---|
date | Mon, 12 Jul 1993 22:13:12 +0000 |
parents | cebb261b0f10 |
children | adf973a863dd |
files | src/getloadavg.c |
diffstat | 1 files changed, 3 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/src/getloadavg.c Mon Jul 12 22:04:35 1993 +0000 +++ b/src/getloadavg.c Mon Jul 12 22:13:12 1993 +0000 @@ -436,7 +436,7 @@ /* Put the 1 minute, 5 minute and 15 minute load averages into the first NELEM elements of LOADAVG. - Return the number written (never more than 3), + Return the number written (never more than 3, but may be less than NELEM), or -1 if an error occurred. */ int @@ -494,12 +494,8 @@ struct processor_set_basic_info info; unsigned info_count; - if (nelem > 1) - { - /* We only know how to get the 1-minute average for this system. */ - errno = EINVAL; - return -1; - } + /* We only know how to get the 1-minute average for this system, + so even if the caller asks for more than 1, we only return 1. */ if (!getloadavg_initialized) {