Hi, in the application that I outlined in my previous email "optimize tramp for many start-file-process'es in parallel", Tramp functionality is invoked asynchronously from within a process sentinel. The functionality has been purposely moved into sentinels in order to keep Emacs responsive during the background compilation, similarly to M-x compile. However, when the user tries to open another file, maybe using completion, he possibly invokes Tramp while another synchronous Tramp call (maybe file-attributes), started from within some sentinel, is running. Consequently the "Forbidden reentrant call of Tramp" error is raised.
How should I design my sentinel, such that this error is avoided? The source code hints to "connection buffers". How do I call file-attributes, such that it uses one connection buffer, while the user is doing file name completion, using a different connection buffer? BTW, thanks for introducing this error protection. When I started with Tramp 2.4, it took quite some debugging until I found out why file-attributes sometimes returned nonsense - the reason were several interleaved calls, apparently using the same Tramp internal data structures. Thanks in advance, Hendrik
