[LTP] [RFC PATCH 1/2] Add support for mixing C and shell code
Martin Doucha
mdoucha@suse.cz
Wed Jul 24 11:53:36 CEST 2024
On 24. 07. 24 11:47, Cyril Hrubis wrote:
> Hi!
>> The exit command above will ignore any other result flags already set
>> during the test. You could modify tst_res_ to return the correct exit
>> code and then call it like this:
>
> It does not work like this. The tst_res helper modifies the shm memory
> that the test library uses, so all test results are propagated once the
> tst_res helper returns.
>
> Only the TBROK flag is not propagated via the shared memory in the new
> test library which I consider a mistake when I designed the new test
> library and we should move it to the shared memory...
That still doesn't solve the incorrect return value from the script if
it's intentionally possible to run it as a stand-alone test, without any
parent process written in C.
--
Martin Doucha mdoucha@suse.cz
SW Quality Engineer
SUSE LINUX, s.r.o.
CORSO IIa
Krizikova 148/34
186 00 Prague 8
Czech Republic
More information about the ltp
mailing list