X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=common-src%2Fdgram.h;h=d791b9a9006c545ece11000228a4d7de1b33daa4;hb=691567b16c13087b31ee4c2b6d038e57872fae82;hp=dbacc9f4b869fd73f1b2a077409468dee39c32b4;hpb=cdbbeef9cde260e429854dd313bc0bf7560e1e24;p=debian%2Famanda diff --git a/common-src/dgram.h b/common-src/dgram.h index dbacc9f..d791b9a 100644 --- a/common-src/dgram.h +++ b/common-src/dgram.h @@ -1,6 +1,7 @@ /* * Amanda, The Advanced Maryland Automatic Network Disk Archiver * Copyright (c) 1991-1999 University of Maryland at College Park + * Copyright (c) 2007-2012 Zmanda, Inc. All Rights Reserved. * All Rights Reserved. * * Permission to use, copy, modify, distribute, and sell this software and its @@ -48,14 +49,14 @@ typedef struct dgram_s { char data[MAX_DGRAM+1]; } dgram_t; -int dgram_bind(dgram_t *dgram, in_port_t *portp); +int dgram_bind(dgram_t *dgram, sa_family_t family, in_port_t *portp); void dgram_socket(dgram_t *dgram, int sock); -int dgram_send(char *hostname, in_port_t port, dgram_t *dgram); -int dgram_send_addr(struct sockaddr_in addr, dgram_t *dgram); -ssize_t dgram_recv(dgram_t *dgram, int timeout, struct sockaddr_in *fromaddr); +int dgram_send_addr(sockaddr_union *addr, dgram_t *dgram); +ssize_t dgram_recv(dgram_t *dgram, int timeout, + sockaddr_union *fromaddr); void dgram_zero(dgram_t *dgram); int dgram_cat(dgram_t *dgram, const char *fmt, ...) - __attribute__ ((format (printf, 2, 3))); + G_GNUC_PRINTF(2,3); void dgram_eatline(dgram_t *dgram); #endif /* ! DGRAM_H */