Lines Matching defs:fp
135 int sepol_set_policydb_from_file(FILE * fp)
140 pf.fp = fp;
1634 int hidden next_entry(void *buf, struct policy_file *fp, size_t bytes)
1638 switch (fp->type) {
1640 nread = fread(buf, bytes, 1, fp->fp);
1646 if (bytes > fp->len)
1648 memcpy(buf, fp->data, bytes);
1649 fp->data += bytes;
1650 fp->len -= bytes;
1659 struct policy_file *fp)
1663 switch (fp->type) {
1665 return fwrite(ptr, size, n, fp->fp);
1667 if (bytes > fp->len) {
1672 memcpy(fp->data, ptr, bytes);
1673 fp->data += bytes;
1674 fp->len -= bytes;
1677 fp->len += bytes;
1708 struct policy_file file, *fp;
1714 fp = &file;
1719 if (policydb_read(&newpolicydb, fp, 1)) {