X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=gdb%2Ftracefile-tfile.c;h=c1a4a49337246e34d9586e4a2a8d8db836002d92;hb=bb1183e25ae74ba21500fb4e39bc1ca9822e3086;hp=0953b03781ff6864db1e3ae4c9fd9d90976ab6a1;hpb=ff8577f64987a898e1dc5eb6afb66a404fb7bb16;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/tracefile-tfile.c b/gdb/tracefile-tfile.c index 0953b03781..c1a4a49337 100644 --- a/gdb/tracefile-tfile.c +++ b/gdb/tracefile-tfile.c @@ -1,6 +1,6 @@ /* Trace file TFILE format support in GDB. - Copyright (C) 1997-2019 Free Software Foundation, Inc. + Copyright (C) 1997-2020 Free Software Foundation, Inc. This file is part of GDB. @@ -557,7 +557,7 @@ tfile_target_open (const char *arg, int from_tty) inferior_appeared (current_inferior (), TFILE_PID); inferior_ptid = ptid_t (TFILE_PID); - add_thread_silent (inferior_ptid); + add_thread_silent (&tfile_ops, inferior_ptid); if (ts->traceframe_count <= 0) warning (_("No traceframes present in this file.")); @@ -616,8 +616,7 @@ tfile_interp_line (char *line, struct uploaded_tp **utpp, void tfile_target::close () { - if (trace_fd < 0) - return; + gdb_assert (trace_fd != -1); inferior_ptid = null_ptid; /* Avoid confusion from thread stuff. */ exit_inferior_silent (current_inferior ());