Lines Matching refs:st
250 static void BN_STACK_init(BN_STACK *st) in BN_STACK_init() argument
252 st->indexes = NULL; in BN_STACK_init()
253 st->depth = st->size = 0; in BN_STACK_init()
256 static void BN_STACK_finish(BN_STACK *st) in BN_STACK_finish() argument
258 OPENSSL_free(st->indexes); in BN_STACK_finish()
259 st->indexes = NULL; in BN_STACK_finish()
263 static int BN_STACK_push(BN_STACK *st, unsigned int idx) in BN_STACK_push() argument
265 if (st->depth == st->size) { in BN_STACK_push()
268 st->size ? (st->size * 3 / 2) : BN_CTX_START_FRAMES; in BN_STACK_push()
275 if (st->depth) in BN_STACK_push()
276 memcpy(newitems, st->indexes, sizeof(*newitems) * st->depth); in BN_STACK_push()
277 OPENSSL_free(st->indexes); in BN_STACK_push()
278 st->indexes = newitems; in BN_STACK_push()
279 st->size = newsize; in BN_STACK_push()
281 st->indexes[(st->depth)++] = idx; in BN_STACK_push()
285 static unsigned int BN_STACK_pop(BN_STACK *st) in BN_STACK_pop() argument
287 return st->indexes[--(st->depth)]; in BN_STACK_pop()