Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
htop
Commits
61f2d674
Commit
61f2d674
authored
Jan 03, 2016
by
Michael McConville
Browse files
Remove NULL-checks before free()
These are never necessary when using the standard library.
parent
be9edc5d
Changes
1
Hide whitespace changes
Inline
Side-by-side
freebsd/FreeBSDProcessList.c
View file @
61f2d674
...
...
@@ -188,10 +188,10 @@ void ProcessList_delete(ProcessList* this) {
const
FreeBSDProcessList
*
fpl
=
(
FreeBSDProcessList
*
)
this
;
if
(
fpl
->
kd
)
kvm_close
(
fpl
->
kd
);
if
(
fpl
->
cp_time_o
!=
NULL
)
free
(
fpl
->
cp_time_o
);
if
(
fpl
->
cp_time_n
!=
NULL
)
free
(
fpl
->
cp_time_n
);
if
(
fpl
->
cp_times_o
!=
NULL
)
free
(
fpl
->
cp_times_o
);
if
(
fpl
->
cp_times_n
!=
NULL
)
free
(
fpl
->
cp_times_n
);
free
(
fpl
->
cp_time_o
);
free
(
fpl
->
cp_time_n
);
free
(
fpl
->
cp_times_o
);
free
(
fpl
->
cp_times_n
);
ProcessList_done
(
this
);
free
(
this
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment