Re: how to reinstall a peer?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Emmanuel Dreyfus <manu@xxxxxxxxxx> wrote:

> glusterd1-xdr.c:
>          if (!xdr_string (xdrs, &objp->op_errstr, ~0))
>                  return FALSE;

How is this supposed to work? Here is below the NetBSD xdr_string()
implementation from libc. Even if objp->op_errstr is not NULL, the
maxsize argument set to 0 will cause it to always retrurn false. Does it
has another semantic in Linux?

bool_t
xdr_string(xdrs, cpp, maxsize)
        XDR *xdrs;
        char **cpp;
        u_int maxsize;
{
(...)
        sp = *cpp;
(...)
        switch (xdrs->x_op) {
(...)
        case XDR_ENCODE:
                size = strlen(sp);
                break;
(...)
        if (size > maxsize) {
                return (FALSE);
        }

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu@xxxxxxxxxx



[Index of Archives]     [Gluster Users]     [Ceph Users]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux