Hi Waldek, what's your view on this patch?

- Qian

On 10/24/24 6:40 PM, Qian Yun wrote:
> There was this problem when using fricas(sman) in a pipe,
> the output may get truncated at beginning or end.
> 
> I used a workaround before, but now I have find the root cause
> and a proper fix.
> 
> First, "expose-bug.patch" in the attachment reverts the workaround
> and expose the bug during the book building.
> 
> The root cause is that, the first prompt is send from "FRICASsys"
> to "session", skipping "sman", causing a race.
> 
> If "session" gets "(1) -> \0" from "FRICASsys", then gets
> "a very long string" from "sman", then the socket may send them
> together, so "spadclient" gets this:
> 
>     "(1) -> \0a very long string"
> 
> When printed by "fputs", those after '\0' is truncated.
> 
> Now, with my patch, the initial prompt is sent from "FRICASsys"
> to terminal, then to "sman", then to "session", then to "spadclient".
> 
> - Qian

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to fricas-devel+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/fricas-devel/28d3eca1-9eac-4112-b973-b196cf8616e8%40gmail.com.

Reply via email to