Lines Matching refs:buflen

200   ctx->buflen = 0;  in __crypt__sha512_init_ctx()
213 uint64_t bytes = ctx->buflen; in __crypt__sha512_finish_ctx()
245 if (ctx->buflen != 0) in __crypt__sha512_process_bytes()
247 size_t left_over = ctx->buflen; in __crypt__sha512_process_bytes()
251 ctx->buflen += add; in __crypt__sha512_process_bytes()
253 if (ctx->buflen > 128) in __crypt__sha512_process_bytes()
255 __crypt__sha512_process_block (ctx->buffer, ctx->buflen & ~127, ctx); in __crypt__sha512_process_bytes()
257 ctx->buflen &= 127; in __crypt__sha512_process_bytes()
260 ctx->buflen); in __crypt__sha512_process_bytes()
294 size_t left_over = ctx->buflen; in __crypt__sha512_process_bytes()
304 ctx->buflen = left_over; in __crypt__sha512_process_bytes()
331 crypt_sha512_r (const char *key, const char *salt, char *buffer, int buflen) in crypt_sha512_r() argument
502 cp = stpncpy (buffer, sha512_salt_prefix, MAX (0, buflen)); in crypt_sha512_r()
503 buflen -= sizeof (sha512_salt_prefix) - 1; in crypt_sha512_r()
507 int n = snprintf (cp, MAX (0, buflen), "%s%zu$", in crypt_sha512_r()
510 buflen -= n; in crypt_sha512_r()
513 cp = stpncpy (cp, salt, MIN ((size_t) MAX (0, buflen), salt_len)); in crypt_sha512_r()
514 buflen -= MIN ((size_t) MAX (0, buflen), salt_len); in crypt_sha512_r()
516 if (buflen > 0) in crypt_sha512_r()
519 --buflen; in crypt_sha512_r()
526 while (n-- > 0 && buflen > 0) \ in crypt_sha512_r()
529 --buflen; \ in crypt_sha512_r()
557 if (buflen <= 0) in crypt_sha512_r()
595 static int buflen; in crypt_sha512() local
600 if (buflen < needed) in crypt_sha512()
607 buflen = needed; in crypt_sha512()
610 return crypt_sha512_r (key, salt, buffer, buflen); in crypt_sha512()