Commit Graph
13 Commits
Author SHA1 Message Date
Cedric Roux 3d78e5a34b add option --T_dont_fork to tracee (lte-softmodem, oaisim)
The T has 2 processes: the tracee and the local tracer
if the tracee dies (segfault or whatever) the tracee
may still be running.

So there is a third process that monitors those two others
and kill everything when one dies.

The problem is that this third process has to be the parent
of the two others. That makes debugging the tracee with gdb
impossible. This new option disables the third monitor process.
2016-06-28 12:50:58 +02:00
Cedric Roux bb051c0219 T_messages.txt is now sent by local_tracer.c
And it's sent at each connection attempt.
Before it was sent only once to the first tracer.
Plus there was a bug (length:(len) should have been length:(send_size)).
2016-06-23 11:09:05 +02:00
Cedric Roux e0966584cf monitor tracee and local tracer to avoid "dead" processes
this may be removed at some point, it's very brutal. But when you
write some code, it may happen (it "may"!!) that *sometimes* the
code does not work and crashes. In thoses cases I prefer the
local tracer (or the tracee) to go away immediately without even
thinking about it maybe still running in the background.

In case of monitoring (as opposed to debugging) maybe it's preferable
to let the process live its life as it wants.

Time will tell.
2016-06-06 12:30:50 +02:00
Cedric Roux 18c2bdda98 don't abord if read fails in get_message
it may legitimately happen when the tracee is ctrl+c'ed.
Let's print something though because read may fail for
other reasons. Why not?
2016-06-05 17:47:08 +02:00
Cedric Roux 358a37910c put local tracer in tracee
plus some cleanup here and there
2016-06-01 15:42:29 +02:00
Cedric Roux 05afc953e8 cleanup - _T_cache variable had no place here... 2016-05-31 18:50:01 +02:00
Cedric Roux 6b9db37802 start integrating local tracer directly into tracee
first step: let the tracee connect before the remote tracer
and let's have a "no wait" mode where the local tracer starts
the tracee before the remote tracer is connected
2016-05-31 17:06:45 +02:00
Cedric Roux a5e63b2726 rename T_SEND to T_COMMIT, sounds better
get rid of T_send(), no use anymore
2016-05-31 15:56:35 +02:00
Cedric Roux 3a71ecb759 remove T_USE_SHARED_MEMORY
The T only works when it's TRUE, the version without shared memory
is not supported anymore.
2016-05-31 15:47:55 +02:00
Cedric Roux 2e64d54e9e the tracee (lte-softmodem) now sends the content of T_messages.txt
as special events.

If we store all received events to a file, this dump is now
self-contained. Helps to analyze traces.

Some functions have also been factorized in the process, too much
duplication.

(Also tracer/Makefile was forgotten in previous commit, included
in this one...)
2016-05-25 14:15:47 +02:00
Cedric Roux e6d5f22c8b add message 1 to the T
This message sends configuration for all events.
2016-05-01 22:39:23 +02:00
Cedric Roux 4e88857b27 let the soft-modem (or the program being traced, whatever it is) try
to connect until it succeeds
2016-04-25 17:27:22 +02:00
Cedric Roux f9d740eee6 first commit of the T - review this commit, many things should
probably not be here.
2016-04-10 17:01:22 +02:00