Draft: missed to test return code of bind()
when we start 2 nodes with rfsim, on same machine and same TCP port, the second bind() fails silently So, the second listen() uses a random port number this commit adds a assert to stop the process
Merge request reports
Activity
requested review from @arashsahbafard
OAI RAN-Container-Parent build (3162): Your merge request should have one of the mandatory labels:
- documentation (don't perform any stages)
- BUILD-ONLY (execute only build stages)
- 4G-LTE (perform 4G tests)
- 5G-NR (perform 5G tests)
- CI (perform both 4G and 5G tests)
Not performing CI due to lack of labels
OAI RAN-Container-Parent build (3162): failed (https://jenkins-oai.eurecom.fr/job/RAN-Container-Parent/3162/)
OAI RAN-CI-develop build (4563): failed (https://open5glab.eurecom.fr:8083/jenkins/job/RAN-CI-develop/4563/)
OAI RAN-CI-develop build (4564): passed (https://open5glab.eurecom.fr:8083/jenkins/job/RAN-CI-develop/4564/)
OAI RAN-Container-Parent build (3163): failed (https://jenkins-oai.eurecom.fr/job/RAN-Container-Parent/3163/)
changed milestone to %REVIEW_CAN_START
assigned to @arashsahbafard
requested review from @schmidtr and removed review request for @arashsahbafard
changed milestone to %REVIEW_COMPLETED_AND_APPROVED
547 547 sin_addr: 548 548 { s_addr: INADDR_ANY } 549 549 }; 550 bind(t->listen_sock, (struct sockaddr *)&addr, sizeof(addr)); 550 AssertFatal(bind(t->listen_sock, (struct sockaddr *)&addr, sizeof(addr))==0,""); Optional: It would be better to decouple function call and assert, and to give a helpful message, something like (untested!):
changed this line in version 2 of the diff
OAI RAN-CI-develop build (4591): passed (https://open5glab.eurecom.fr:8083/jenkins/job/RAN-CI-develop/4591/)
OAI RAN-Container-Parent build (3190): failed (https://jenkins-oai.eurecom.fr/job/RAN-Container-Parent/3190/)
@arashsahbafard @lthomas I squashed the commits into one, improved the commit message, and preserved the authorship of Arash. Nothing to be done from your side, the commits are equal, so the CI run is valid (it is ok).
changed milestone to %OK_TO_BE_MERGED
mentioned in merge request !1800 (merged)
mentioned in commit 0cacf29d