Current-Users archive

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

Compile error in compat_crypto_50



For a few days now I'm unable to compile -current modules on Alpha
either natively or cross-compiled due to the following error:

--- dependall-compat_crypto_50 ---
/raid/src/sys/opencrypto/ocryptodev.h: In function 'ocryptof_ioctl':
/raid/src/sys/opencrypto/ocryptodev.c:284:16: error: 'os_op.ses' may be
used uninitialized in this function [-Werror=maybe-uninitialized]
   osn_ops->ses =  os_op.ses;
   ~~~~~~~~~~~~~^~~~~~~~~~~~
/raid/src/sys/opencrypto/ocryptodev.c:275:22: note: 'os_op.ses' was
declared here
   struct osession_op os_op;
                      ^~~~~
cc1: all warnings being treated as errors

It's here in the function for ocryptodev_msession, which is
structurally identical to the function for ocryptodev_session just
preceding it (so it's not clear to this amateur why it should
complain):

static int
ocryptodev_msession(struct fcrypt *fcr, struct osession_n_op *osn_ops,
                   int count)
{
        int i;

        for (i = 0; i < count; i++, osn_ops++) {
                struct osession_op os_op;
                os_op.cipher =          osn_ops->cipher;
                os_op.mac =             osn_ops->mac;
                os_op.keylen =          osn_ops->keylen;
                os_op.key =             osn_ops->key;
                os_op.mackeylen =       osn_ops->mackeylen;
                os_op.mackey =          osn_ops->mackey;

                osn_ops->status = ocryptodev_session(fcr, &os_op);
                osn_ops->ses =          os_op.ses;
        }

        return 0;
}

It seems like it could be a quick fix but I'll file a bug if needed.

Thanks,
David



Home | Main Index | Thread Index | Old Index