Browse Source

simulator_mavlink: consistent system call scope operator

sbg
Matthias Grob 6 years ago committed by Daniel Agar
parent
commit
73f4706597
  1. 10
      src/modules/simulator/simulator_mavlink.cpp

10
src/modules/simulator/simulator_mavlink.cpp

@ -679,8 +679,8 @@ void Simulator::pollForMAVLinkMessages(bool publish) @@ -679,8 +679,8 @@ void Simulator::pollForMAVLinkMessages(bool publish)
while (true) {
// Once we receive something, we're most probably good and can carry on.
int len = recvfrom(_fd, _buf, sizeof(_buf), 0,
(struct sockaddr *)&_srcaddr, (socklen_t *)&_addrlen);
int len = ::recvfrom(_fd, _buf, sizeof(_buf), 0,
(struct sockaddr *)&_srcaddr, (socklen_t *)&_addrlen);
if (len > 0) {
break;
@ -716,7 +716,7 @@ void Simulator::pollForMAVLinkMessages(bool publish) @@ -716,7 +716,7 @@ void Simulator::pollForMAVLinkMessages(bool publish)
break;
} else {
close(_fd);
::close(_fd);
system_sleep(1);
}
}
@ -798,8 +798,8 @@ void Simulator::pollForMAVLinkMessages(bool publish) @@ -798,8 +798,8 @@ void Simulator::pollForMAVLinkMessages(bool publish)
if (fds[0].revents & POLLIN) {
int len = recvfrom(_fd, _buf, sizeof(_buf), 0,
(struct sockaddr *)&_srcaddr, (socklen_t *)&_addrlen);
int len = ::recvfrom(_fd, _buf, sizeof(_buf), 0,
(struct sockaddr *)&_srcaddr, (socklen_t *)&_addrlen);
if (len > 0) {
mavlink_message_t msg;

Loading…
Cancel
Save