Added "Fall through" comments to some switch statements where multiple
approaches are tried in order to prevent warnings from GCC 7 (and newer). Added includes on Linux for sys/sysmacros.h as the old defines in the sys/types.h file will be removed in the future.
This commit is contained in:
parent
cfb39b573f
commit
e0cfd39728
@ -25,6 +25,10 @@ sysvinit (2.90) UNRELEASED; urgency=low
|
||||
can be used to make sure init does not have any files open. However,
|
||||
it also means we cannot switch run levels or bring down the system.
|
||||
The pipe can be re-opened by sending init the SIGUSR1 signal.
|
||||
* Added "Fall through" comments to some switch statements where multiple
|
||||
approaches are tried in order to prevent warnings from GCC 7 (and newer).
|
||||
* Added includes on Linux for sys/sysmacros.h as the old defines in
|
||||
the sys/types.h file will be removed in the future.
|
||||
|
||||
|
||||
sysvinit (2.89) world; urgency=low
|
||||
|
@ -33,6 +33,7 @@
|
||||
# include <sys/vt.h>
|
||||
# include <sys/kd.h>
|
||||
# include <linux/serial.h>
|
||||
#include <sys/sysmacros.h>
|
||||
#endif
|
||||
#include <fcntl.h>
|
||||
#include <dirent.h>
|
||||
|
@ -233,6 +233,7 @@ static int do_standby_disk(char *device, unsigned int flags)
|
||||
case DISK_EXTFLUSH:
|
||||
if ((ret = ioctl(fd, HDIO_DRIVE_CMD, &flush1)) == 0)
|
||||
break;
|
||||
/* Else Fall through */
|
||||
/* Extend flush rejected, try standard flush */
|
||||
default:
|
||||
ret = ioctl(fd, HDIO_DRIVE_CMD, &flush2) &&
|
||||
|
@ -1318,6 +1318,7 @@ void startup(CHILD *ch)
|
||||
case POWERFAIL:
|
||||
case ONCE:
|
||||
if (ch->flags & XECUTED) break;
|
||||
/* Fall through */
|
||||
case ONDEMAND:
|
||||
case RESPAWN:
|
||||
ch->flags |= RUNNING;
|
||||
|
@ -653,6 +653,7 @@ int readproc(int do_stat)
|
||||
case DO_NETFS:
|
||||
if ((p->nfs = check4nfs(path, buf)))
|
||||
goto link;
|
||||
/* else fall through */
|
||||
case DO_STAT:
|
||||
if (stat(path, &st) != 0) {
|
||||
char * ptr;
|
||||
|
@ -41,6 +41,9 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/wait.h>
|
||||
#ifdef __linux__
|
||||
#include <sys/sysmacros.h> /* brought in my LFS patch */
|
||||
#endif
|
||||
#include <time.h>
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
|
@ -32,6 +32,9 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/wait.h>
|
||||
#ifdef __linux__
|
||||
#include <sys/sysmacros.h>
|
||||
#endif
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
Loading…
Reference in New Issue
Block a user