Skip to content
Snippets Groups Projects
Commit 2b8c751f authored by Michael Paquier's avatar Michael Paquier
Browse files

Add pg_attribute_noreturn() to all the main routines of bgworkers

Those routines should never return and exit properly, so mark them
as such as a saity measure.
parent 022c5741
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -34,7 +34,7 @@
PG_MODULE_MAGIC;
 
void _PG_init(void);
void count_relations_main(Datum main_arg);
void count_relations_main(Datum main_arg) pg_attribute_noreturn();
 
static volatile sig_atomic_t got_sigterm = false;
 
Loading
Loading
Loading
Loading
@@ -32,7 +32,7 @@
PG_MODULE_MAGIC;
 
void _PG_init(void);
void hello_notify_main(Datum main_arg);
void hello_notify_main(Datum main_arg) pg_attribute_noreturn();
 
/* Worker name */
static const char *hello_notify_name = "hello_notify";
Loading
Loading
Loading
Loading
@@ -25,7 +25,7 @@ PG_MODULE_MAGIC;
 
/* Entry point of library loading */
void _PG_init(void);
void hello_main(Datum main_arg);
void hello_main(Datum main_arg) pg_attribute_noreturn();
 
/* SIGTERM handling */
static volatile sig_atomic_t got_sigterm = false;
Loading
Loading
Loading
Loading
@@ -26,7 +26,7 @@ PG_MODULE_MAGIC;
/* Entry point of library loading */
void _PG_init(void);
/* Main loop of process */
void hello_main(Datum main_arg)
void hello_main(Datum main_arg) pg_attribute_noreturn();
 
/* Signal handling */
static volatile sig_atomic_t got_sigterm = false;
Loading
Loading
Loading
Loading
@@ -31,7 +31,7 @@ PG_MODULE_MAGIC;
 
/* Entry point of library loading */
void _PG_init(void);
void kill_idle_main(Datum main_arg);
void kill_idle_main(Datum main_arg) pg_attribute_noreturn();
 
/* Signal handling */
static volatile sig_atomic_t got_sigterm = false;
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment