+2019-10-07 Omar Sandoval <osandov@fb.com>
+
+ * dwfl_frame.c (dwfl_getthreads): Get rid of unnecessary
+ thread_free_all_states calls.
+ (getthread): Ditto.
+
2019-08-12 Mark Wielaard <mark@klomp.org>
* gzip.c (open_stream): Return DWFL_E_ERRNO on bad file operation.
process->callbacks_arg,
&thread.callbacks_arg);
if (thread.tid < 0)
- {
- Dwfl_Error saved_errno = dwfl_errno ();
- thread_free_all_states (&thread);
- __libdwfl_seterrno (saved_errno);
- return -1;
- }
+ return -1;
if (thread.tid == 0)
{
- thread_free_all_states (&thread);
__libdwfl_seterrno (DWFL_E_NOERROR);
return 0;
}
int err = callback (&thread, arg);
if (err != DWARF_CB_OK)
- {
- thread_free_all_states (&thread);
- return err;
- }
+ return err;
assert (thread.unwound == NULL);
}
/* NOTREACHED */
if (process->callbacks->get_thread (dwfl, tid, process->callbacks_arg,
&thread.callbacks_arg))
{
- int err;
thread.tid = tid;
- err = callback (&thread, arg);
- thread_free_all_states (&thread);
- return err;
+ return callback (&thread, arg);
}
return -1;