[PATCH] prepare streams based messaging

Amitay Isaacs amitay at gmail.com
Wed Jun 1 06:44:53 UTC 2016


On Sat, May 28, 2016 at 1:01 AM, Volker Lendecke <Volker.Lendecke at sernet.de>
wrote:

> Hi!
>
> Attached find two patches: The first is a set of patches preparing the
> second one. "look" cleans up some dependencies, making some
> infrastructure more generally useful. I'd like to put that in now.
> Review appreciated!
>
> The second one, "tfd", is the start of what I've talked about @
> sambaxp. It's the stream socket introducer. Our plan is to also use it
> for ctdb communication, I've already done some changes after talking
> to Amitay about it. So, not really used yet, but if you're curious,
> feel free to take a look :-)
>
> Thanks, Volker


I uncovered a problem while trying to run the tests fddrn/fdsrc.

I tried to run fddrn as follows:

    $ bin/fddrn bin/tfdd /tmp/tfd
    tfd_init failed: No such file or directory

While debugging this, I figured out that the tfdd path needs to be absolute.

Q: Do you need to do chdir("/") in tfd_tfdd_child()?  Can we do that in
tfdd binary?

Since exeve failed, tfd_spawn_tfdd() returned EBUSY.  So I guess the check
for ret needs be fixed.

@@ -104,7 +104,7 @@ int tfd_init(const char *tfdd_exec, const char
*tfdd_sock,
                      sizeof(state->addr));
        if ((ret == -1) && (state->tfdd_exec[0] != '\0')) {
                ret = tfd_spawn_tfdd(state->tfdd_exec, tfdd_sock);
-               if (ret == -1) {
+               if (ret != 0) {
                        goto fail;
                }
                ret = connect(state->sock,


Amitay.


More information about the samba-technical mailing list