]> git.alsa-project.org Git - alsa-plugins.git/commitdiff
remove unused <byteswap.h>, use getprogname() for *BSDs
authorSASANO Takayoshi <uaa@uaa.org.uk>
Tue, 3 Jan 2023 08:38:13 +0000 (17:38 +0900)
committerJaroslav Kysela <perex@perex.cz>
Mon, 10 Jun 2024 09:03:44 +0000 (11:03 +0200)
Closes: https://github.com/alsa-project/alsa-plugins/pull/48
Signed-off-by: SASANO Takayoshi <uaa@uaa.org.uk>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
jack/pcm_jack.c
usb_stream/pcm_usb_stream.c

index f266a35180e30c3fc4567dbbc953d895991e4706..0bdb6880ee081f8c083a4292d09fff10f8083233 100644 (file)
@@ -23,7 +23,6 @@
 #define _GNU_SOURCE
 #include <stdbool.h>
 #include <errno.h>
-#include <byteswap.h>
 #include <sys/shm.h>
 #include <sys/types.h>
 #include <sys/socket.h>
@@ -603,7 +602,11 @@ static int snd_pcm_jack_open(snd_pcm_t **pcmp, const char *name,
        }
 
        if (client_name == NULL) {
+#if defined(__linux__)
                const char *pname = program_invocation_short_name;
+#else
+               const char *pname = getprogname();
+#endif
                if (!pname[0]) {
                        pname = "alsa-jack";
                }
index 02d2f43c085e4a475f05d28895d7a16b3658f03e..86ec1a38dcb50f1a78b9543ca903660a613a254e 100644 (file)
@@ -19,7 +19,6 @@
  */
 
 #define _GNU_SOURCE
-#include <byteswap.h>
 #include <sys/mman.h>
 #include <sys/shm.h>
 #include <sys/ioctl.h>