You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Doug MacEachern <do...@opengroup.org> on 1997/07/03 17:42:00 UTC

connection handles

I need to get at the client RPC handle during authorization and a few
other places, but at the moment, I have to dig it out of the sfio
discipline like so:

static h_t *find_handle(request_rec *r)
{
    Sfdisc_t *disc = sfdisc(r->connection->client->sf_in, SF_POPDISC);
    h_t *h = ((wand_disc_t *)disc)->ch;
    sfdisc(r->connection->client->sf_in, disc);
    return h;
}

This is not ideal.  The directory and request config creation stuff
happens at the wrong place and time for the dce stuff to do this
right.  What would be ideal, with the tiny patch below, I can save a
pointer to the rpc handle right after bcreate(), then the routine I
can use later in the request stages looks like so:

static h_t *find_handle(request_rec *r)
{
    return ((h_t *)r->connection->client->t_handle);
}

If there's a way to do something like this already, I'd be happy to
hear it. 

-Doug


*** ./buff.h.orig	Mon Jun 30 21:00:14 1997
--- ./buff.h	Thu Jul  3 11:35:01 1997
***************
*** 101,106 ****
--- 101,109 ----
      int fd;                /* the file descriptor */
      int fd_in;             /* input file descriptor, if different */
  
+     /* transport handle, can be used to store things such as an RPC binding handle */
+     void *t_handle;
+ 
  #ifdef B_SFIO
      Sfio_t   *sf_in;
      Sfio_t   *sf_out;

Re: connection handles

Posted by Dean Gaudet <dg...@arctic.org>.
Isn't this specific to B_SFIO stuff ?  I'm not clear on what the
"transport handle" means ... 

Dean

On Thu, 3 Jul 1997, Doug MacEachern wrote:

> *** ./buff.h.orig	Mon Jun 30 21:00:14 1997
> --- ./buff.h	Thu Jul  3 11:35:01 1997
> ***************
> *** 101,106 ****
> --- 101,109 ----
>       int fd;                /* the file descriptor */
>       int fd_in;             /* input file descriptor, if different */
>   
> +     /* transport handle, can be used to store things such as an RPC binding handle */
> +     void *t_handle;
> + 
>   #ifdef B_SFIO
>       Sfio_t   *sf_in;
>       Sfio_t   *sf_out;
>