Skip to content

Commit

Permalink
cppcheck: silence warning
Browse files Browse the repository at this point in the history
Signed-off-by: Markus Klotzbuecher <mk@mkio.de>
  • Loading branch information
kmarkus committed Jul 22, 2020
1 parent 8df55fa commit b1acf39
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions std_blocks/mqueue/mqueue.c
Original file line number Diff line number Diff line change
Expand Up @@ -170,15 +170,14 @@ int mqueue_init(ubx_block_t *i)

void mqueue_cleanup(ubx_block_t *i)
{
int ret;
struct mqueue_info *inf = (struct mqueue_info *)i->private_data;

if (mq_close(inf->mqd) != 0)
ubx_err(i, "mq_close %s failed: %s", inf->mq_name, strerror(errno));

if (inf->unlink) {
ubx_info(i, "%s: removing mq %s", __func__, inf->mq_name);
ret = mq_unlink(inf->mq_name);
int ret = mq_unlink(inf->mq_name);

if (ret < 0 && errno != ENOENT)
ubx_err(i, "mq_unlink %s failed: %s", inf->mq_name, strerror(errno));
Expand Down

0 comments on commit b1acf39

Please sign in to comment.