fatal("key_free: bad key type %d", a->type);
fatal("key_equal: bad key type %d", a->type);
key_equal(Key *a, Key *b){	if (a == NULL || b == NULL || a->type != b->type)		return 0;	switch (a->type) {	case KEY_RSA:		return a->rsa != NULL && b->rsa != NULL &&		    BN_cmp(a->rsa->e, b->rsa->e) == 0 &&		    BN_cmp(a->rsa->n, b->rsa->n) == 0;		break;	case KEY_DSA:		return a->dsa != NULL && b->dsa != NULL &&		    BN_cmp(a->dsa->p, b->dsa->p) == 0 &&		    BN_cmp(a->dsa->q, b->dsa->q) == 0 &&		    BN_cmp(a->dsa->g, b->dsa->g) == 0 &&		    BN_cmp(a->dsa->pub_key, b->dsa->pub_key) == 0;		break;	default:		fatal("key_free: bad key type %d", a->type);		break;	}	return 0;}