Lines Matching refs:f
589 FILE *f; in mbedtls_ctr_drbg_write_seed_file() local
592 if ((f = fopen(path, "wb")) == NULL) { in mbedtls_ctr_drbg_write_seed_file()
597 mbedtls_setbuf(f, NULL); in mbedtls_ctr_drbg_write_seed_file()
604 if (fwrite(buf, 1, MBEDTLS_CTR_DRBG_MAX_INPUT, f) != in mbedtls_ctr_drbg_write_seed_file()
614 fclose(f); in mbedtls_ctr_drbg_write_seed_file()
622 FILE *f = NULL; in mbedtls_ctr_drbg_update_seed_file() local
627 if ((f = fopen(path, "rb")) == NULL) { in mbedtls_ctr_drbg_update_seed_file()
632 mbedtls_setbuf(f, NULL); in mbedtls_ctr_drbg_update_seed_file()
634 n = fread(buf, 1, sizeof(buf), f); in mbedtls_ctr_drbg_update_seed_file()
635 if (fread(&c, 1, 1, f) != 0) { in mbedtls_ctr_drbg_update_seed_file()
639 if (n == 0 || ferror(f)) { in mbedtls_ctr_drbg_update_seed_file()
643 fclose(f); in mbedtls_ctr_drbg_update_seed_file()
644 f = NULL; in mbedtls_ctr_drbg_update_seed_file()
650 if (f != NULL) { in mbedtls_ctr_drbg_update_seed_file()
651 fclose(f); in mbedtls_ctr_drbg_update_seed_file()