예제 #1
0
파일: zcert.c 프로젝트: shemminger/czmq
void
zcert_apply (zcert_t *self, void *zocket)
{
    assert (self);
#if (ZMQ_VERSION_MAJOR == 4)
    zsocket_set_curve_secretkey_bin (zocket, self->secret_key);
    zsocket_set_curve_publickey_bin (zocket, self->public_key);
#endif
}
예제 #2
0
파일: zcert.c 프로젝트: PSG-Luna/czmq
void
zcert_apply (zcert_t *self, void *zocket)
{
    assert (self);
#if (ZMQ_VERSION_MAJOR == 4)
    void *handle = zsock_resolve (zocket);
    if (zsys_has_curve ()) {
        zsocket_set_curve_secretkey_bin (handle, self->secret_key);
        zsocket_set_curve_publickey_bin (handle, self->public_key);
    }
#endif
}