]> git.meshlink.io Git - catta/blobdiff - avahi-dnsconfd/main.c
update man pages
[catta] / avahi-dnsconfd / main.c
index 84b0f6873cd076696c689ba85d504ecf57794084..b384a038e0df19196c76cf40a7d2f702afec1435 100644 (file)
 #include <config.h>
 #endif
 
-#include <sys/un.h>
 #include <fcntl.h>
 #include <unistd.h>
 #include <sys/select.h>
 #include <sys/socket.h>
+#include <sys/un.h>
 #include <errno.h>
 #include <string.h>
 #include <stdio.h>
@@ -287,7 +287,7 @@ static int new_line(const char *l) {
         AvahiIfIndex interface;
         AvahiProtocol protocol;
         int i_interface, i_protocol, port;
-        char a[64];
+        char a[AVAHI_ADDRESS_STR_MAX];
         
         assert(state == BROWSING); 
 
@@ -296,7 +296,7 @@ static int new_line(const char *l) {
             return -1;
         }
 
-        if (sscanf(l+1, "%i %i %64s %i", &i_interface, &i_protocol, a, &port) != 4) {
+        if (sscanf(l+1, "%i %i %39s %i", &i_interface, &i_protocol, a, &port) != 4) {
             daemon_log(LOG_ERR, "Failed to parse browsing line: %s", l);
             return -1;
         }
@@ -588,7 +588,7 @@ int main(int argc, char *argv[]) {
                 /** Parent **/
 
                 if ((ret = daemon_retval_wait(20)) < 0) {
-                    daemon_log(LOG_ERR, "Could not recieve return value from daemon process.");
+                    daemon_log(LOG_ERR, "Could not receive return value from daemon process.");
                     goto finish;
                 }