mirror of
https://github.com/radio95-rnt/rds95.git
synced 2026-02-26 12:32:05 +01:00
wtf is this (vibe)
This commit is contained in:
16
src/rds95.c
16
src/rds95.c
@@ -134,8 +134,20 @@ int main(int argc, char **argv) {
|
||||
|
||||
pthread_attr_init(&attr);
|
||||
|
||||
signal(SIGTERM, stop);
|
||||
signal(SIGHUP, reload);
|
||||
struct sigaction sa_hup, sa_term;
|
||||
|
||||
memset(&sa_hup, 0, sizeof(sa_hup));
|
||||
sa_hup.sa_handler = reload;
|
||||
sigemptyset(&sa_hup.sa_mask);
|
||||
sa_hup.sa_flags = SA_RESTART;
|
||||
sigaction(SIGHUP, &sa_hup, NULL);
|
||||
|
||||
memset(&sa_term, 0, sizeof(sa_term));
|
||||
sa_term.sa_handler = stop;
|
||||
sigemptyset(&sa_term.sa_mask);
|
||||
sa_term.sa_flags = SA_RESTART;
|
||||
sigaction(SIGTERM, &sa_term, NULL);
|
||||
sigaction(SIGINT, &sa_term, NULL);
|
||||
|
||||
format.format = PA_SAMPLE_FLOAT32NE;
|
||||
format.channels = config.num_streams;
|
||||
|
||||
Reference in New Issue
Block a user