Changes in / [1543:9222d31123b1:1544:7bad8025e69d] in freeDiameter
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
contrib/debian/changelog
r1398 r1542 1 freediameter (UNRELEASED) UNRELEASED; urgency=low 2 3 * freeDiameter: 4 - Add -g to help 5 - Change -d and -q to control syslog level, as per stdout logging. 6 - Syslog to LOG_DAEMON. 7 - Actually syslog to LOG_DEBUG, now that -d/-q are used. 8 - Add -p pidfile 9 - SCTP client: bind to local endpoints configured with ListenOn so 10 that the SCTP INIT only contains those local endpoint addresses, 11 matching what is advertised in the CER. 12 * Base dictionary: Add rules for Experimental-Result. 13 * All extensions: Hide symbols except for fd_ext_init() and fd_ext_fini(). 14 * dbg_dict_dump.fdx: add extension to write the dictionary 15 to the given file or to the log. 16 * dbg_dict_dump_json.fdx: add extension to write the dictionary as JSON 17 to the given file or stdout. 18 * dict_dcca_3gpp.fdx: Update to 3GPP Release 15, adding many standards. 19 This adds 96 TYPEs, 145 ENUMVALs, 791 AVPs, 52 RULEs. 20 There are various breaking changes (documented below). 21 * contrib/dictionary_dcca_3gpp.json: Remove non-3GPP AVPs that are 22 actually from base IETF RFCs: 23 - MIP6-Feature-Vector (124). IETF RFC 5447 24 - Service-Selection (493). IETF RFC 5778 25 - Mobile-Node-Identifier (506). IETF RFC 5779 26 - QoS-Capability (578). IETF RFC 5777. 27 * New API: fd_msg_add_result(): set Result-Code or Experimental-Result. 28 * New API: log level FD_LOG_INFO. 29 * fd_conf_dump(): fix formatting of local endpoints. 30 * fd_msg_search_avp(): support searching avp as well as msg. 31 * Fix compiler warnings. 32 * Add ERRORS_ON_WARNINGS cmake boolean to enable fatal compiler warnings. 33 * New tool: grep_fd_dict_dump: cleanup fd_dict_dump() output in logs. 34 * New tool: csv_to_fd: convert .csv with AVP tables to freeDiameter C or JSON. 35 * New tool: org_to_csv: convert .org files into .csv files. 36 37 * dict_dcca_3gpp.fdx changes per update to 3GPP Release 15 as at 2019-12: 38 - AVP changes: 39 - 3GPP-CG-IPv6-Address (14) renamed to 3GPP-CG-Ipv6-Address (14). 40 - 3GPP-GGSN-IPv6-Address (16) renamed to 3GPP-GGSN-Ipv6-Address (16). 41 - 3GPP-IPv6-DNS-Servers (17) renamed to 3GPP-Ipv6-DNS-Servers (17). 42 - 3GPP-SGSN-IPv6-Address (15) renamed to 3GPP-SGSN-Ipv6-Address (15). 43 - 3GPP2-BSID (9010) flag M MUST. 44 - 3GPP2-BSID (9010) type changed from OctetString to UTF8String. 45 - ADC-Revalidation-Time (2801) Time removed in 3GPP TS 29.212 V12.1.0 (2013-06). 46 - ADC-Rule-Base-Name (1095) flag M MUST. 47 - ADC-Rule-Definition (1094) flag M MUST. 48 - ADC-Rule-Install (1092) flag M MUST. 49 - ADC-Rule-Name (1096) flag M MUST. 50 - ADC-Rule-Remove (1093) flag M MUST. 51 - ADC-Rule-Report (1097) flag M MUST. 52 - Application-Service-Type (2102) type changed from UTF8String to Enumerated. 53 - Application–Session–Id (2103) type changed from UTF8String to Unsigned32. 54 - Call-Barring-Infor-List (1488) renamed to Call-Barring-Info (1488). 55 - External-Identifier (28) OctetString replaced by External-Identifier (3111) UTF8String. 56 - LCS-Requestor-Id (1239) renamed to LCS-Requestor-ID (1239). 57 - LCS-Requestor-Id-String (1240) renamed to LCS-Requestor-ID-String (1240). 58 - MBMS-BMSC-SSM-IPv6-Address (919) renamed to MBMS-BMSC-SSM-Ipv6-Address (919). 59 - MBMS-GGSN-IPv6-Address (917) renamed to MBMS-GGSN-Ipv6-Address (917). 60 - MBMSGW-Address (2307) renamed to MBMS-GW-Address (2307). 61 - Measurement-Period-LTE (1656) code changed to Measurement-Period-LTE (1655). 62 - Measurement-Period-UMTS (1655) code changed to Measurement-Period-UMTS (1656). 63 - MME-LocationInformation (1600) renamed to MME-Location-Information(1600). 64 - PDG-Address (895) Address removed in 3GPP TS 32.299 V12.6.0 (2014-09). 65 - PDG-Charging-Id (896) Unsigned32 removed in 3GPP TS 32.299 V12.6.0 (2014-09). 66 - PDN-Connection-ID (1065) flag M MUST NOT. 67 - PoC-User-Role-info-Units (1254) renamed to PoC-User-Role-Info-Units (1254). 68 - PS-to-CS-Session-Continuity (1099) flag M MUST NOT. 69 - SS-Status (1477) type changed from Grouped to OctetString. 70 - Status (2702) renamed to Status-AS-Code (2702). 71 - WAG-Address (890) Address removed in 3GPP TS 32.299 V12.6.0 (2014-09). 72 - WAG-PLMN-Id (891) OctetString removed in 3GPP TS 32.299 V12.6.0 (2014-09). 73 - WLAN-Information (875) Grouped removed in 3GPP TS 32.299 V12.6.0 (2014-09). 74 - WLAN-Radio-Container (892) Grouped removed in 3GPP TS 32.299 V12.6.0 (2014-09). 75 - WLAN-Session-Id (1246) UTF8String removed in 3GPP TS 32.299 V12.6.0 (2014-09). 76 - WLAN-Technology (893) Unsigned32 removed in 3GPP TS 32.299 V12.6.0 (2014-09). 77 - WLAN-UE-Local-IPAddress (894) Address removed in 3GPP TS 32.299 V12.6.0 (2014-09). 78 - AVP renames: 79 - Rename Call-Barring-Infor-List (1488) to Call-Barring-Info (1488). 80 - Rename LCS-Requestor-Id (1239) to LCS-Requestor-ID (1239). 81 - Rename LCS-Requestor-Id-String (1240) to LCS-Requestor-ID-String (1240). 82 - Rename MBMSGW-Address (2307) to MBMS-GW-Address (2307). 83 - Rename MME-LocationInformation (1600) to MME-Location-Information(1600). 84 - Rename PoC-User-Role-info-Units (1254) to PoC-User-Role-Info-Units (1254). 85 - Rename Status (2702) to Status-AS-Code (2702). 86 - AVP name conflicts: 87 - Time-Window (3818) in 3GPP TS 29.345 V12.1.0 (2014-12) predates 88 Time-Window-29.154 (4204) in 3GPP TS 29.154 V13.1.0 (2016-03). 89 - Add Enumerated(3GPP/Experimental-Result-Code). 145 values. 90 - Update standards: 91 - 3GPP TS 29.061 V15.5.0 (2018-12). 15 AVPs. 92 - 3GPP TS 29.173 V15.0.0 (2018-06). 1 AVP. 93 - 3GPP TS 29.212 V15.9.0 (2019-12). 46 AVPs. 94 - 3GPP TS 29.214 V15.7.0 (2019-09). 27 AVPs. 95 - 3GPP TS 29.229 V15.2.0 (2019-09). 8 AVPs. 96 - 3GPP TS 29.272 V15.10.0 (2019-12). 44 AVPs. 97 - 3GPP TS 29.329 V15.2.0 (2019-09). 5 AVPs. 98 - 3GPP TS 32.299 V15.7.0 (2019-06). 154 AVPs. 99 - Add standards: 100 - 3GPP TS 29.109 V15.0.0 (2017-06). 21 AVPs. 101 - 3GPP TS 29.128 V15.6.0 (2019-09). 25 AVPs. 102 - 3GPP TS 29.153 V15.1.0 (2019-09). 2 AVPs. 103 - 3GPP TS 29.154 V15.3.0 (2019-09). 16 AVPs. 104 - 3GPP TS 29.172 V15.2.0 (2019-12). 66 AVPs. 105 - 3GPP TS 29.209 V6.8.0 (2011-09). 2 AVPs. 106 - 3GPP TS 29.215 V15.2.0 (2019-09). 9 AVPs. 107 - 3GPP TS 29.217 V15.1.0 (2019-09). 14 AVPs. 108 - 3GPP TS 29.219 V15.3.0 (2019-09). 7 AVPs. 109 - 3GPP TS 29.234 V11.2.0 (2013-06). 19 AVPs. 110 - 3GPP TS 29.273 V15.4.0 (2019-09). 40 AVPs. 111 - 3GPP TS 29.283 V15.1.0 (2019-09). 16 AVPs. 112 - 3GPP TS 29.336 V15.7.0 (2019-09). 79 AVPs. 113 - 3GPP TS 29.337 V15.0.0 (2018-06). 4 AVPs. 114 - 3GPP TS 29.338 V15.1.0 (2018-12). 34 AVPs. 115 - 3GPP TS 29.343 V15.1.0 (2019-09). 13 AVPs. 116 - 3GPP TS 29.344 V15.1.0 (2019-09). 7 AVPs. 117 - 3GPP TS 29.345 V15.1.0 (2019-09). 68 AVPs. 118 - 3GPP TS 29.368 V15.1.0 (2019-09). 12 AVPs. 119 - 3GPP TS 29.388 V15.1.0 (2019-09). 3 AVPs. 120 - 3GPP TS 29.389 V15.1.0 (2019-09). 3 AVPs. 121 - 3GPP TS 29.468 V15.8.0 (2019-12). 33 AVPs. 122 - 3GPP TS 29.561 V16.3.0 (2020-03). 9 AVPs. 123 1 124 freediameter (1.4.0) RELEASED; urgency=low 2 125 -
include/freeDiameter/libfdcore.h
r1425 r1540 152 152 unsigned pr_tcp : 1; /* prefer TCP over SCTP */ 153 153 unsigned tls_alg: 1; /* TLS algorithm for initiated cnx. 0: separate port. 1: inband-security (old) */ 154 unsigned no_bind: 1; /* disable client bind to cnf_endpoints if non configured (bind all) */ 154 155 } cnf_flags; 155 156 -
libfdcore/cnxctx.c
r1419 r1540 331 331 } 332 332 333 /* Same for SCTP, accepts a list of remote addresses to connect to (see sctp_connectx for how they are used) */ 334 struct cnxctx * fd_cnx_cli_connect_sctp(int no_ip6, uint16_t port, struct fd_list * list) 333 /* Same for SCTP, accepts a list of remote addresses to connect to (see sctp_connectx for how they are used). 334 * If src_list is not NULL and not empty, list of local addresses to connect from via sctp_bindx(). */ 335 struct cnxctx * fd_cnx_cli_connect_sctp(int no_ip6, uint16_t port, struct fd_list * list, struct fd_list * src_list) 335 336 { 336 337 #ifdef DISABLE_SCTP … … 345 346 sSS primary; 346 347 347 TRACE_ENTRY("%p ",list);348 TRACE_ENTRY("%p %p", list, src_list); 348 349 CHECK_PARAMS_DO( list && !FD_IS_LIST_EMPTY(list), return NULL ); 349 350 351 /* Log SCTP association source and destination endpoints */ 352 { 353 char * buf = NULL; 354 size_t len = 0, offset = 0; 355 CHECK_MALLOC_DO( fd_dump_extend( &buf, &len, &offset, "Connecting SCTP endpoints"), ); 356 CHECK_MALLOC_DO( fd_dump_extend( &buf, &len, &offset, " source: "), ); 357 if (src_list && !FD_IS_LIST_EMPTY(src_list)) { 358 CHECK_MALLOC_DO( fd_ep_dump( &buf, &len, &offset, 0, 0, src_list ), ); 359 } else { 360 CHECK_MALLOC_DO( fd_dump_extend( &buf, &len, &offset, "(ANY)"), ); 361 } 362 CHECK_MALLOC_DO( fd_dump_extend( &buf, &len, &offset, ", destination: "), ); 363 CHECK_MALLOC_DO( fd_ep_dump( &buf, &len, &offset, 0, 0, list ), ); 364 LOG_D("%s", buf ?: "Error determining SCTP endpoints"); 365 free(buf); 366 } 367 350 368 fd_sa_sdump_numeric(sa_buf, &((struct fd_endpoint *)(list->next))->sa); 351 369 … … 353 371 354 372 { 355 int ret = fd_sctp_client( &sock, no_ip6, port, list );373 int ret = fd_sctp_client( &sock, no_ip6, port, list, src_list ); 356 374 if (ret != 0) { 357 375 LOG_D("SCTP connection to [%s,...] failed: %s", sa_buf, strerror(ret)); -
libfdcore/cnxctx.h
r1421 r1540 118 118 int fd_sctp_create_bind_server( int * sock, int family, struct fd_list * list, uint16_t port ); 119 119 int fd_sctp_listen( int sock ); 120 int fd_sctp_client( int *sock, int no_ip6, uint16_t port, struct fd_list * list );120 int fd_sctp_client( int *sock, int no_ip6, uint16_t port, struct fd_list * list, struct fd_list * src_list ); 121 121 int fd_sctp_get_local_ep(int sock, struct fd_list * list); 122 122 int fd_sctp_get_remote_ep(int sock, struct fd_list * list); -
libfdcore/config.c
r1415 r1540 148 148 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " - Pref. proto .. : %s\n", fd_g_config->cnf_flags.pr_tcp ? "TCP" : "SCTP"), return NULL); 149 149 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " - TLS method ... : %s\n", fd_g_config->cnf_flags.tls_alg ? "INBAND" : "Separate port"), return NULL); 150 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " - Client bind .. : %s\n", fd_g_config->cnf_flags.no_bind ? "DISABLED" : "Enabled"), return NULL); 150 151 151 152 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " TLS : - Certificate .. : %s\n", fd_g_config->cnf_sec_data.cert_file ?: "(NONE)"), return NULL); … … 352 353 353 354 /* Validate local endpoints */ 354 if ((!FD_IS_LIST_EMPTY(&fd_g_config->cnf_endpoints)) && (fd_g_config->cnf_flags.no_ip4 || fd_g_config->cnf_flags.no_ip6)) { 355 fd_g_config->cnf_flags.no_bind = FD_IS_LIST_EMPTY(&fd_g_config->cnf_endpoints); 356 if ((!fd_g_config->cnf_flags.no_bind) && (fd_g_config->cnf_flags.no_ip4 || fd_g_config->cnf_flags.no_ip6)) { 355 357 struct fd_list * li; 356 358 for ( li = fd_g_config->cnf_endpoints.next; li != &fd_g_config->cnf_endpoints; li = li->next) { -
libfdcore/fdcore-internal.h
r1397 r1540 343 343 struct cnxctx * fd_cnx_serv_accept(struct cnxctx * serv); 344 344 struct cnxctx * fd_cnx_cli_connect_tcp(sSA * sa, socklen_t addrlen); 345 struct cnxctx * fd_cnx_cli_connect_sctp(int no_ip6, uint16_t port, struct fd_list * list );345 struct cnxctx * fd_cnx_cli_connect_sctp(int no_ip6, uint16_t port, struct fd_list * list, struct fd_list * src_list); 346 346 int fd_cnx_start_clear(struct cnxctx * conn, int loop); 347 347 void fd_cnx_sethostname(struct cnxctx * conn, DiamId_t hn); -
libfdcore/p_cnx.c
r1203 r1540 262 262 switch (nc->proto) { 263 263 case IPPROTO_TCP: 264 /* TODO: use no_bind and first of cnf_endpoints of nc->ss.sa_family ? */ 264 265 cnx = fd_cnx_cli_connect_tcp((sSA *)&nc->ss, sSAlen(&nc->ss)); 265 266 break; … … 267 268 case IPPROTO_SCTP: 268 269 cnx = fd_cnx_cli_connect_sctp((peer->p_hdr.info.config.pic_flags.pro3 == PI_P3_IP) ? 1 : fd_g_config->cnf_flags.no_ip6, 269 nc->port, &peer->p_hdr.info.pi_endpoints); 270 nc->port, &peer->p_hdr.info.pi_endpoints, 271 fd_g_config->cnf_flags.no_bind ? NULL : &fd_g_config->cnf_endpoints); 270 272 break; 271 273 #endif /* DISABLE_SCTP */ -
libfdcore/sctp.c
r1543 r1544 59 59 #endif /* USE_DEFAULT_SCTP_RTX_PARAMS */ 60 60 61 62 DECLARE_FD_DUMP_PROTOTYPE(fd_sa_dump_array, sSA * saddrs, int saddrs_count) 63 { 64 union { 65 sSA *sa; 66 uint8_t *buf; 67 } ptr; 68 int i; 69 int salen; 70 71 FD_DUMP_HANDLE_OFFSET(); 72 73 ptr.sa = saddrs; 74 for (i = 0; i < saddrs_count; i++) { 75 salen = sSAlen(ptr.sa); 76 if (salen == 0) { 77 LOG_E("fd_sa_dump_array: Unknown sockaddr family"); 78 break; 79 } 80 if (i > 0) { 81 CHECK_MALLOC_DO( fd_dump_extend( FD_DUMP_STD_PARAMS, " "), return NULL); 82 } 83 CHECK_MALLOC_DO( fd_sa_dump( FD_DUMP_STD_PARAMS, ptr.sa, NI_NUMERICHOST | NI_NUMERICSERV), return NULL); 84 ptr.buf += salen; 85 } 86 return *buf; 87 } 88 61 89 /* Pre-binding socket options -- # streams read in config */ 62 90 static int fd_setsockopt_prebind(int sk) … … 815 843 goto redo; 816 844 } 817 818 #if 0 819 union { 820 sSA *sa; 821 uint8_t *buf; 822 } ptr; 823 int i; 824 ptr.sa = sar; 825 fd_log_debug("Calling sctp_bindx with the following address array:"); 826 for (i = 0; i < count; i++) { 827 TRACE_sSA(FD_LOG_DEBUG, FULL, " - ", ptr.sa, NI_NUMERICHOST | NI_NUMERICSERV, "" ); 828 ptr.buf += (ptr.sa->sa_family == AF_INET) ? sizeof(sSA4) : sizeof(sSA6) ; 829 } 830 #endif 831 845 846 /* Debug: show bound addresses */ 847 { 848 char * buf = NULL; 849 size_t len = 0; 850 CHECK_MALLOC_DO( fd_sa_dump_array( &buf, &len, 0, sar, count), ); 851 LOG_D("SCTP server binding local addresses: %s", buf); 852 free(buf); 853 } 854 832 855 /* Bind to this array */ 833 856 CHECK_SYS( sctp_bindx(*sock, sar, count, SCTP_BINDX_ADD_ADDR) ); … … 841 864 842 865 /* Debug: show all local listening addresses */ 843 #if 0 844 sSA *sar; 845 union { 846 sSA *sa; 847 uint8_t *buf; 848 } ptr; 849 int sz; 850 866 { 867 sSA *sar = NULL; 868 int sz = 0; 869 char * buf = NULL; 870 size_t len = 0; 871 851 872 CHECK_SYS( sz = sctp_getladdrs(*sock, 0, &sar) ); 852 853 fd_log_debug("SCTP server bound on :"); 854 for (ptr.sa = sar; sz-- > 0; ptr.buf += (ptr.sa->sa_family == AF_INET) ? sizeof(sSA4) : sizeof(sSA6)) { 855 TRACE_sSA(FD_LOG_DEBUG, FULL, " - ", ptr.sa, NI_NUMERICHOST | NI_NUMERICSERV, "" ); 856 } 873 874 CHECK_MALLOC_DO( fd_sa_dump_array( &buf, &len, 0, sar, sz), ); 875 LOG_D("SCTP server locally bound addresses: %s", buf); 857 876 sctp_freeladdrs(sar); 858 #endif 877 free(buf); 878 } 859 879 860 880 return 0; … … 870 890 871 891 /* Create a client socket and connect to remote server */ 872 int fd_sctp_client( int *sock, int no_ip6, uint16_t port, struct fd_list * list )892 int fd_sctp_client( int *sock, int no_ip6, uint16_t port, struct fd_list * list, struct fd_list * src_list ) 873 893 { 874 894 int family; … … 880 900 int count = 0; 881 901 int ret; 902 int bind_default = 1; /* enable ASCONF in postbind */ 882 903 883 904 sar.buf = NULL; 884 905 885 TRACE_ENTRY("%p %i %hu %p ", sock, no_ip6, port,list);906 TRACE_ENTRY("%p %i %hu %p %p", sock, no_ip6, port, list, src_list); 886 907 CHECK_PARAMS( sock && list && (!FD_IS_LIST_EMPTY(list)) ); 908 CHECK_PARAMS( !src_list || (src_list && (!FD_IS_LIST_EMPTY(src_list))) ); 887 909 888 910 if (no_ip6) { … … 900 922 /* Set the socket options */ 901 923 CHECK_FCT_DO( ret = fd_setsockopt_prebind(*sock), goto out ); 902 924 925 /* Bind to explicit source addresses if requested */ 926 if (src_list && !FD_IS_LIST_EMPTY(src_list)) { 927 sSA * bindsar = NULL; /* array of addresses */ 928 size_t sz = 0; /* size of the array */ 929 int sarcount = 0; /* number of sock addr in the array */ 930 931 /* Create the array of configured addresses */ 932 CHECK_FCT_DO( ret = add_addresses_from_list_mask((void *)&bindsar, &sz, &sarcount, family, 0, src_list, EP_FL_CONF, EP_FL_CONF), goto out ); 933 934 if (sarcount) { 935 char * buf = NULL; 936 size_t len = 0; 937 CHECK_MALLOC_DO( fd_sa_dump_array( &buf, &len, 0, bindsar, sarcount), goto out ); 938 LOG_A("SCTP client binding local addresses: %s", buf); 939 free(buf); 940 941 CHECK_SYS_DO( ret = sctp_bindx(*sock, bindsar, sarcount, SCTP_BINDX_ADD_ADDR), goto out ); 942 } 943 944 /* Disable ASCONF option in postbind */ 945 bind_default = 0; 946 947 /* We don't need bindsar anymore */ 948 free(bindsar); 949 } 950 903 951 /* Create the array of addresses, add first the configured addresses, then the discovered, then the other ones */ 904 952 CHECK_FCT_DO( ret = add_addresses_from_list_mask(&sar.buf, &size, &count, family, htons(port), list, EP_FL_CONF, EP_FL_CONF ), goto out ); … … 907 955 908 956 /* Try connecting */ 909 LOG_A("Attempting SCTP connection (%d addresses attempted) ", count); 910 911 #if 0 912 /* Dump the SAs */ 913 union { 914 uint8_t *buf; 915 sSA *sa; 916 sSA4 *sin; 917 sSA6 *sin6; 918 } ptr; 919 int i; 920 ptr.buf = sar.buf; 921 for (i=0; i< count; i++) { 922 TRACE_sSA(FD_LOG_DEBUG, FULL, " - ", ptr.sa, NI_NUMERICHOST | NI_NUMERICSERV, "" ); 923 ptr.buf += (ptr.sa->sa_family == AF_INET) ? sizeof(sSA4) : sizeof(sSA6); 924 } 925 #endif 926 957 { 958 char * buf = NULL; 959 size_t len = 0; 960 CHECK_MALLOC_DO( fd_sa_dump_array( &buf, &len, 0, sar.sa, count), goto out ); 961 LOG_A("SCTP client connecting to addresses: %s", buf); 962 free(buf); 963 } 964 927 965 /* Bug in some Linux kernel, the sctp_connectx is not a cancellation point. To avoid blocking freeDiameter, we allow async cancel here */ 928 966 pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL); … … 945 983 946 984 /* Set the remaining sockopts */ 947 CHECK_FCT_DO( ret = fd_setsockopt_postbind(*sock, 1),985 CHECK_FCT_DO( ret = fd_setsockopt_postbind(*sock, bind_default), 948 986 { 949 987 CHECK_SYS_DO( shutdown(*sock, SHUT_RDWR), /* continue */ ); … … 983 1021 #if 0 984 1022 char sa_buf[sSA_DUMP_STRLEN]; 985 fd_sa_sdump_numeric(sa_buf, &status.sstat_primary.spinfo_address);1023 fd_sa_sdump_numeric(sa_buf, (sSA *)&status.sstat_primary.spinfo_address); 986 1024 fd_log_debug( "SCTP_STATUS : sstat_state : %i" , status.sstat_state); 987 1025 fd_log_debug( " sstat_rwnd : %u" , status.sstat_rwnd); … … 1219 1257 if (mhdr.msg_flags & MSG_NOTIFICATION) { 1220 1258 union sctp_notification * notif = (union sctp_notification *) data; 1259 char sa_buf[sSA_DUMP_STRLEN]; 1221 1260 1222 1261 TRACE_DEBUG(FULL, "Received %zdb data of notification on socket %d", datasize, conn->cc_socket); … … 1236 1275 case SCTP_PEER_ADDR_CHANGE: 1237 1276 TRACE_DEBUG(FULL, "Received SCTP_PEER_ADDR_CHANGE notification"); 1238 /* TRACE_sSA(FD_LOG_DEBUG, ANNOYING, " intf_change : ", &(notif->sn_paddr_change.spc_aaddr), NI_NUMERICHOST | NI_NUMERICSERV, "" ); */ 1277 fd_sa_sdump_numeric(sa_buf, (sSA *)&(notif->sn_paddr_change.spc_aaddr)); 1278 TRACE_DEBUG(ANNOYING, " intf_change : %s", sa_buf); 1239 1279 TRACE_DEBUG(ANNOYING, " state : %d", notif->sn_paddr_change.spc_state); 1240 1280 TRACE_DEBUG(ANNOYING, " error : %d", notif->sn_paddr_change.spc_error); -
libfdproto/fifo.c
r1405 r1539 171 171 { 172 172 struct fifo * q; 173 #if defDEBUG173 #ifndef NDEBUG 174 174 int loops = 0; 175 175 #endif … … 228 228 int fd_fifo_move ( struct fifo * old, struct fifo * new, struct fifo ** loc_update ) 229 229 { 230 #if defDEBUG230 #ifndef NDEBUG 231 231 int loops = 0; 232 232 #endif … … 421 421 queue->thrs_push-- ; 422 422 423 #if ndefDEBUG423 #ifdef NDEBUG 424 424 (void)ret; 425 425 #endif -
libfdproto/messages.c
r1442 r1539 2285 2285 if (msg->msg_model != NULL) { 2286 2286 /* Check if this model is still valid for the message data */ 2287 #if defDEBUG2287 #ifndef NDEBUG 2288 2288 enum dict_object_type dicttype; 2289 2289 #endif -
tests/testcnx.c
r1399 r1540 675 675 case IPPROTO_SCTP: 676 676 { 677 cnx = fd_cnx_cli_connect_sctp(0, TEST_PORT, &eps );677 cnx = fd_cnx_cli_connect_sctp(0, TEST_PORT, &eps, NULL); 678 678 CHECK( 1, (cnx ? 1 : 0) ^ cf->expect_failure ); 679 679 } -
tests/testsctp.c
r1235 r1540 99 99 100 100 /* Now, create the client socket */ 101 CHECK( 0, fd_sctp_client( &cli.cc_socket, 0, TEST_PORT, &eps ));101 CHECK( 0, fd_sctp_client( &cli.cc_socket, 0, TEST_PORT, &eps, NULL )); 102 102 103 103 /* Accept this connection */
Note: See TracChangeset
for help on using the changeset viewer.