/*
- * Copyright (C) 2011 - David Goulet <david.goulet@polymtl.ca>
- * Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
- * 2013 - Jérémie Galarneau <jeremie.galarneau@efficios.com>
+ * Copyright (C) 2011 David Goulet <david.goulet@polymtl.ca>
+ * Copyright (C) 2011 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+ * Copyright (C) 2013 Jérémie Galarneau <jeremie.galarneau@efficios.com>
*
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License, version 2 only,
- * as published by the Free Software Foundation.
+ * SPDX-License-Identifier: GPL-2.0-only
*
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#include <stddef.h>
uint32_t revents = LTTNG_POLL_GETEV(&events, i);
int pollfd = LTTNG_POLL_GETFD(&events, i);
- if (!revents) {
- /* No activity for this FD (poll implementation). */
- continue;
- }
-
cds_list_for_each_entry_safe(wait_node, tmp_wait_node,
&wait_queue->head, head) {
if (pollfd == wait_node->app->sock &&
}
lttng_fd_put(LTTNG_FD_APPS, 1);
free(ust_cmd);
+ ust_cmd = NULL;
goto error;
}
CDS_INIT_LIST_HEAD(&wait_node->head);
}
lttng_fd_put(LTTNG_FD_APPS, 1);
free(wait_node);
+ wait_node = NULL;
free(ust_cmd);
+ ust_cmd = NULL;
continue;
}
/*
wait_queue.count++;
free(ust_cmd);
+ ust_cmd = NULL;
/*
* We have to continue here since we don't have the notify
* socket and the application MUST be added to the hash table
wait_queue.count--;
app = wait_node->app;
free(wait_node);
+ wait_node = NULL;
DBG3("UST app notify socket %d is set", ust_cmd->sock);
break;
}
lttng_fd_put(LTTNG_FD_APPS, 1);
}
free(ust_cmd);
+ ust_cmd = NULL;
}
if (app) {