]> code.delx.au - pulseaudio/blobdiff - src/utils/pax11publish.c
client-conf: Remove redundant function parameters
[pulseaudio] / src / utils / pax11publish.c
index 6600363b1613c27f7b0dc523e74e7dc2903b563a..f79975dd0c49f804c318116cdf9cee589de25551 100644 (file)
 
 #include <stdio.h>
 #include <getopt.h>
-#include <string.h>
 #include <assert.h>
 #include <locale.h>
 
 #include <xcb/xcb.h>
 
 #include <pulse/util.h>
-#include <pulse/i18n.h>
 #include <pulse/client-conf.h>
 
 #include <pulsecore/core-util.h>
+#include <pulsecore/i18n.h>
 #include <pulsecore/log.h>
 #include <pulsecore/authkey.h>
 #include <pulsecore/native-common.h>
 #include <pulsecore/x11prop.h>
 
-
 int main(int argc, char *argv[]) {
     const char *dname = NULL, *sink = NULL, *source = NULL, *server = NULL, *cookie_file = PA_NATIVE_COOKIE_FILE;
     int c, ret = 1, screen = 0;
@@ -49,7 +47,9 @@ int main(int argc, char *argv[]) {
     enum { DUMP, EXPORT, IMPORT, REMOVE } mode = DUMP;
 
     setlocale(LC_ALL, "");
+#ifdef ENABLE_NLS
     bindtextdomain(GETTEXT_PACKAGE, PULSE_LOCALEDIR);
+#endif
 
     while ((c = getopt(argc, argv, "deiD:S:O:I:c:hr")) != -1) {
         switch (c) {
@@ -152,7 +152,7 @@ int main(int argc, char *argv[]) {
             char hx[PA_NATIVE_COOKIE_LENGTH*2+1];
             assert(conf);
 
-            if (pa_client_conf_load(conf, NULL) < 0) {
+            if (pa_client_conf_load(conf) < 0) {
                 fprintf(stderr, _("Failed to load client configuration file.\n"));
                 goto finish;
             }
@@ -194,7 +194,7 @@ int main(int argc, char *argv[]) {
 
             pa_client_conf_free(conf);
 
-            if (pa_authkey_load_auto(cookie_file, cookie, sizeof(cookie)) < 0) {
+            if (pa_authkey_load_auto(cookie_file, true, cookie, sizeof(cookie)) < 0) {
                 fprintf(stderr, _("Failed to load cookie data\n"));
                 goto finish;
             }