mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-20 04:48:06 +01:00
wmaker: Added attribute 'noreturn' to appropriate functions
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
committed by
Carlos R. Mafra
parent
34089d7661
commit
6dda67bc51
@@ -387,7 +387,7 @@ static void handle_inotify_events(int fd, int wd)
|
|||||||
* Calls inotifyGetEvents if defaults database changes.
|
* Calls inotifyGetEvents if defaults database changes.
|
||||||
*----------------------------------------------------------------------
|
*----------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
void EventLoop(void)
|
noreturn void EventLoop(void)
|
||||||
{
|
{
|
||||||
XEvent event;
|
XEvent event;
|
||||||
#ifdef HAVE_INOTIFY
|
#ifdef HAVE_INOTIFY
|
||||||
|
|||||||
@@ -22,9 +22,15 @@
|
|||||||
#ifndef WMEVENT_H
|
#ifndef WMEVENT_H
|
||||||
#define WMEVENT_H
|
#define WMEVENT_H
|
||||||
|
|
||||||
|
#include "config.h"
|
||||||
|
|
||||||
|
#ifdef HAVE_STDNORETURN
|
||||||
|
#include <stdnoreturn.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
typedef void (WDeathHandler)(pid_t pid, unsigned int status, void *cdata);
|
typedef void (WDeathHandler)(pid_t pid, unsigned int status, void *cdata);
|
||||||
|
|
||||||
void EventLoop(void);
|
noreturn void EventLoop(void);
|
||||||
void DispatchEvent(XEvent *event);
|
void DispatchEvent(XEvent *event);
|
||||||
void ProcessPendingEvents(void);
|
void ProcessPendingEvents(void);
|
||||||
WMagicNumber wAddDeathHandler(pid_t pid, WDeathHandler *callback, void *cdata);
|
WMagicNumber wAddDeathHandler(pid_t pid, WDeathHandler *callback, void *cdata);
|
||||||
|
|||||||
@@ -269,7 +269,7 @@ static int initWVisualID(const char *user_str)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Exit(int status)
|
noreturn void Exit(int status)
|
||||||
{
|
{
|
||||||
if (dpy)
|
if (dpy)
|
||||||
XCloseDisplay(dpy);
|
XCloseDisplay(dpy);
|
||||||
@@ -464,7 +464,7 @@ Bool RelaunchWindow(WWindow *wwin)
|
|||||||
*
|
*
|
||||||
*----------------------------------------------------------------------
|
*----------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
void wAbort(Bool dumpCore)
|
noreturn void wAbort(Bool dumpCore)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
WScreen *scr;
|
WScreen *scr;
|
||||||
|
|||||||
10
src/main.h
10
src/main.h
@@ -22,12 +22,18 @@
|
|||||||
#ifndef WMMAIN_H_
|
#ifndef WMMAIN_H_
|
||||||
#define WMMAIN_H_
|
#define WMMAIN_H_
|
||||||
|
|
||||||
void Exit(int status) __attribute__((noreturn));
|
#include "config.h"
|
||||||
|
|
||||||
|
#ifdef HAVE_STDNORETURN
|
||||||
|
#include <stdnoreturn.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
noreturn void Exit(int status);
|
||||||
void Restart(char *manager, Bool abortOnFailure);
|
void Restart(char *manager, Bool abortOnFailure);
|
||||||
void SetupEnvironment(WScreen *scr);
|
void SetupEnvironment(WScreen *scr);
|
||||||
void ExecuteShellCommand(WScreen *scr, char *command);
|
void ExecuteShellCommand(WScreen *scr, char *command);
|
||||||
Bool RelaunchWindow(WWindow *wwin);
|
Bool RelaunchWindow(WWindow *wwin);
|
||||||
void wAbort(Bool dumpCore);
|
noreturn void wAbort(Bool dumpCore);
|
||||||
void ExecExitScript(void);
|
void ExecExitScript(void);
|
||||||
int getWVisualID(int screen);
|
int getWVisualID(int screen);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user