freebsd11_network: Add another missing NULL check to taskqueue_free.
Also add missing \ns to the new printfs.
This commit is contained in:
@@ -213,7 +213,7 @@ _callout_stop_safe(struct callout *c, int safe)
|
||||
MutexLocker locker(sLock);
|
||||
|
||||
if (c == NULL) {
|
||||
printf("_callout_stop_safe called with NULL callout");
|
||||
printf("_callout_stop_safe called with NULL callout\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -220,6 +220,11 @@ taskqueue_start_threads(struct taskqueue **taskQueue, int count, int priority,
|
||||
void
|
||||
taskqueue_free(struct taskqueue *taskQueue)
|
||||
{
|
||||
if (taskQueue == NULL) {
|
||||
printf("taskqueue_free called with NULL taskqueue\n");
|
||||
return;
|
||||
}
|
||||
|
||||
/* lock and drain list? */
|
||||
taskQueue->tq_flags &= ~TQ_FLAGS_ACTIVE;
|
||||
if (!taskQueue->tq_fast)
|
||||
@@ -248,7 +253,7 @@ taskqueue_drain(struct taskqueue *taskQueue, struct task *task)
|
||||
cpu_status status;
|
||||
|
||||
if (taskQueue == NULL) {
|
||||
printf("taskqueue_drain called with NULL taskqueue");
|
||||
printf("taskqueue_drain called with NULL taskqueue\n");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user