/illumos-gate/usr/src/lib/lvm/libmeta/common/ |
H A D | meta_mdcf.c | 55 FILE *tfp = NULL; local 66 if ((tfp = fopen(tname, "w")) == NULL) 69 (void) fchmod(fileno(tfp), (sbuf.st_mode & 0777)); 70 (void) fchown(fileno(tfp), sbuf.st_uid, sbuf.st_gid); 76 "# do not hand edit\n"), tfp) == EOF) { 82 if (meta_print_all(sp, tname, NULL, tfp, options, NULL, ep) != 0) 86 if (fclose(tfp) != 0) { 90 tfp = NULL; 99 if ((tfp = fopen(tname, "r")) == NULL) { 105 while (fgets(line, 1000, tfp) ! [all...] |
H A D | meta_patch.c | 65 FILE *tfp = NULL; local 107 if ((tfp = fopen(*tname, "w")) == NULL) { 111 if (fchmod(fileno(tfp), (sbuf.st_mode & 0777)) != 0) { 115 if (fchown(fileno(tfp), sbuf.st_uid, sbuf.st_gid) != 0) { 136 if (fputs(buf, tfp) == EOF) { 158 if (fprintf(tfp, "%s\t%s\t%s\t%s\t%s\t%s\t%s\n", 183 if ((fflush(tfp) != 0) || 184 (fsync(fileno(tfp)) != 0) || 185 (fclose(tfp) != 0)) { 189 tfp [all...] |
H A D | meta_systemfile.c | 63 FILE **tfp, /* returned open FILE */ 76 assert(tfp != NULL); 79 *tfp = NULL; 93 if ((*tfp = fopen(*tname, "w")) == NULL) { 109 if ((*tfp = fopen(*tname, "w")) == NULL) { 115 if ((fchmod(fileno(*tfp), (sbuf.st_mode & 0777)) 117 (fchown(fileno(*tfp), sbuf.st_uid, sbuf.st_gid) 156 if (fputs(buf, *tfp) == EOF) { 181 if ((fflush(*tfp) != 0) || 182 (fsync(fileno(*tfp)) ! 56 meta_systemfile_copy( char *sname, int doroot, int domddb, int doit, int verbose, char **tname, FILE **tfp, md_error_t *ep ) argument 208 meta_systemfile_append_mdroot( mdname_t *rootnp, char *sname, char *tname, FILE *tfp, int ismeta, int doit, int verbose, md_error_t *ep ) argument 337 meta_systemfile_append_mddb( char *cname, char *sname, char *tname, FILE *tfp, int doit, int verbose, int check, md_error_t *ep ) argument [all...] |
/illumos-gate/usr/src/lib/fm/topo/libtopo/common/ |
H A D | topo_file.c | 49 topo_file_unload(topo_file_t *tfp) argument 52 if (tfp == NULL) 55 if (tfp->tf_filenm != NULL) 56 topo_mod_strfree(tfp->tf_mod, tfp->tf_filenm); 58 if (tfp->tf_tmap != NULL) 59 tf_info_free(tfp->tf_mod, tfp->tf_tmap); 61 topo_mod_free(tfp->tf_mod, tfp, sizeo 68 topo_file_t *tfp; local [all...] |
/illumos-gate/usr/src/cmd/fm/eversholt/common/ |
H A D | eftwrite.c | 102 FILE *tfp; local 108 if ((tfp = tmpfile()) == NULL) 111 /* XXX switch stdout to tfp temporarily */ 113 out_altfp(tfp); 116 rewind(tfp); 143 while ((cc = fread(buf, 1, BUFLEN, tfp)) > 0) { 149 if (ferror(tfp)) 151 rewind(tfp); 172 while ((cc = fread(buf, 1, BUFLEN, tfp)) > 0) { 181 if (ferror(tfp)) [all...] |
H A D | eftread.c | 79 FILE *tfp; local 168 if ((tfp = tmpfile()) == NULL) 178 if (cc != fwrite(buf, 1, cc, tfp) || ferror(tfp)) 188 (void) fclose(tfp); 199 rewind(tfp); 201 return (tfp);
|
/illumos-gate/usr/src/cmd/ipf/lib/common/ |
H A D | ipft_hx.c | 25 static FILE *tfp = NULL; variable 31 if (tfp && tfd != -1) { 32 rewind(tfp); 38 tfp = stdin; 42 tfp = fdopen(tfd, "r"); 74 while (fgets(line, sizeof(line)-1, tfp)) {
|
H A D | ipft_td.c | 53 static FILE *tfp = NULL; variable 65 tfp = stdin; 68 tfp = fdopen(tfd, "r"); 76 (void) fclose(tfp); 103 if (!fgets(lbuf, sizeof(lbuf) - 1, tfp))
|
H A D | ipft_tx.c | 41 static FILE *tfp = NULL; variable 123 if (tfp && tfd != -1) { 124 rewind(tfp); 130 tfp = stdin; 134 tfp = fdopen(tfd, "r"); 157 while (fgets(line, sizeof(line)-1, tfp)) {
|
/illumos-gate/usr/src/cmd/saf/ |
H A D | admutil.c | 173 * tfp - destination file's file pointer 179 copy_file(FILE *fp, FILE *tfp, int start, int finish) argument 208 if (fputs(dummy, tfp) == EOF) 220 if (fputs(dummy, tfp) == EOF)
|
H A D | pmadm.c | 555 FILE *tfp; /* file pointer for temp file */ local 587 tfp = open_temp(tname); 589 if (copy_file(fp, tfp, 1, line - 1)) { 595 if (copy_file(fp, tfp, line + 1, -1)) { 601 if (fclose(tfp) == EOF) { 643 FILE *tfp; /* file pointer for temp file */ local 679 tfp = open_temp(tname); 681 if (copy_file(fp, tfp, 1, line - 1)) { 739 (void) fprintf(tfp, "%s", tbuf); 741 if (copy_file(fp, tfp, lin [all...] |
H A D | sacadm.c | 683 FILE *tfp; /* file pointer for temp file */ local 699 tfp = open_temp(tname); 701 if (copy_file(fp, tfp, 1, line - 1)) { 707 if (copy_file(fp, tfp, line + 1, -1)) { 713 if (fclose(tfp) == EOF) {
|
/illumos-gate/usr/src/cmd/refer/ |
H A D | sortbib.c | 44 FILE *fp[MXFILES], *tfp; local 82 if ((tfp = fopen(tempfile, "w")) == NULL) { 87 sortbib(fp[i], tfp, i); 88 fclose(tfp); 89 deliver(fp, tfp); /* do disk seeks and read from biblio files */ 98 sortbib(FILE *fp, FILE *tfp, int i) argument 131 fprintf(tfp, "%d %d %d : %s %s %s %s\n", 134 if (ferror(tfp)) { 156 fprintf(tfp, "%d %d %d : %s %s %s %s\n", 158 if (ferror(tfp)) { 167 deliver(FILE *fp[], FILE *tfp) argument [all...] |
/illumos-gate/usr/src/cmd/ttymon/ |
H A D | sttydefs.c | 321 FILE *tfp; /* file pointer for temp file */ local 346 tfp = open_temp(tname); 348 if (copy_file(fp, tfp, 1, line - 1)) { 352 if (copy_file(fp, tfp, line + 1, -1)) { 357 if (fclose(tfp) == EOF) { 411 * tfp - destination file's file pointer 418 copy_file(fp, tfp, start, finish) 420 FILE *tfp; 451 if (fputs(dummy, tfp) == EOF) 463 if (fputs(dummy, tfp) [all...] |
/illumos-gate/usr/src/lib/lvm/libsvm/common/ |
H A D | update_mdconf.c | 154 * *tfp - File pointer to the md.conf.tmp file. 162 parse_bootlist(char *line, FILE *tfp) argument 211 if (fprintf(tfp, "%s", output) < 0) { 243 FILE *tfp; local 256 if ((tfp = fopen(tname, "a")) == NULL) 264 if (fprintf(tfp, "%s", NEW_BEGMDDBSTR) < 0) { 273 if (fprintf(tfp, "%s", NEW_ENDMDDBSTR) < 0) { 284 rval = parse_bootlist(buf, tfp); 291 if (fprintf(tfp, "%s\n", buf) < 0) { 301 (void) fclose(tfp); [all...] |
/illumos-gate/usr/src/cmd/cmd-inet/usr.bin/rdist/ |
H A D | docmd.c | 508 FILE *tfp; variable 544 tfp = NULL; 546 if ((tfp = fopen(Tmpfile, "w")) == NULL) { 567 if (tfp != NULL) 568 (void) fclose(tfp); 625 log(tfp, "new: %s\n", name);
|
/illumos-gate/usr/src/cmd/cmd-inet/usr.lib/inetd/ |
H A D | repval.c | 461 FILE *tfp; /* temp fp */ local 481 if ((tfp = fdopen(tfd, "w")) == NULL) { 489 if (fprintf(tfp, "%lld\n", spval->val) <= 0) { 490 (void) fclose(tfp); 495 if (fclose(tfp) != 0) { 536 FILE *tfp; /* temp fp */ local 562 if ((tfp = fopen(genfmri_filename, "r")) == NULL) { 571 while ((fscanf_ret = fscanf(tfp, "%lld", &tval)) == 1) { 588 if (fclose(tfp) != 0) { 642 FILE *tfp; /* tem local [all...] |
/illumos-gate/usr/src/cmd/cron/ |
H A D | crontab.c | 411 FILE *tfp; local 430 if ((tfp = fdopen(t, "w")) == NULL) { 502 if (fputs(line, tfp) == EOF) { 508 fclose(tfp); 514 /* make file tfp the new crontab */
|
/illumos-gate/usr/src/cmd/rcm_daemon/common/ |
H A D | filesys_rcm.c | 566 FILE *tfp; local 581 tfp = fopen(tmp, "w"); 582 if (tfp == NULL) { 618 if (fputs(l, tfp) == EOF) { 629 if (tfp) 630 (void) fclose(tfp);
|
/illumos-gate/usr/src/cmd/logadm/ |
H A D | conf.c | 454 FILE *cfp = NULL, *tfp = NULL; local 507 if ((tfp = fdopen(tfd, "w")) == NULL) 511 conf_print(cfp, tfp); 514 if (tfp != NULL && fclose(tfp) < 0)
|
/illumos-gate/usr/src/cmd/fs.d/nfs/nfslog/ |
H A D | nfslog_trans.c | 292 struct nfslog_trans_file *tfp; local 294 for (tfp = trans_file_head; tfp != NULL; tfp = tfp->next) { 295 if ((strcmp(path, tfp->path) == 0) && 296 (output_type == tfp->trans_output_type) && 297 (transtolog == tfp->trans_to_log)) { 300 (tfp->refcnt)++; 301 return (tfp); [all...] |
/illumos-gate/usr/src/uts/common/fs/ |
H A D | dnlc.c | 1666 dcfree_t **prevpp, *tfp; local 1698 tfp = *prevpp; 1703 tfp); 1731 dcfree_t **prevpp, *tfp; local 1758 tfp = *prevpp; 1762 kmem_cache_free(dnlc_dir_space_cache, tfp); 1980 dcfree_t **newhash, *dfp, **nhp, *tfp; local 2010 tfp = dfp; 2012 nhp = &newhash[DDFHASH(tfp->df_handle, dcp)]; 2013 tfp [all...] |
/illumos-gate/usr/src/uts/i86pc/os/ |
H A D | fakebop.c | 1680 bop_trap(ulong_t *tfp) argument 1682 struct trapframe *tf = (struct trapframe *)tfp; 1698 tf = (struct trapframe *)(tfp - 1); 1712 fakeframe.old_frame = (bop_frame_t *)*(tfp - 3);
|
/illumos-gate/usr/src/cmd/sendmail/src/ |
H A D | queue.c | 352 register SM_FILE_T *tfp; local 384 tfp = e->e_lockfp; 385 if (tfp == NULL && newid) 399 (tfp = sm_io_open(SmFtStdiofd, SM_TIME_DEFAULT, 408 tf, (int) geteuid(), tfd, tfp); 411 e->e_lockfp = tfp; 468 if (tfd < 0 || (tfp = sm_io_open(SmFtStdiofd, SM_TIME_DEFAULT, 498 sm_dprintf(" tfp="); 499 dumpfd(sm_io_getinfo(tfp, SM_IO_WHAT_FD, NULL), true, false); 610 (void) sm_io_fprintf(tfp, SM_TIME_DEFAUL [all...] |
/illumos-gate/usr/src/cmd/cmd-inet/usr.sbin/ipqosconf/ |
H A D | ipqosconf.c | 1752 FILE *tfp; local 1766 tfp = validmod(module_name, &openerr); 1767 if (tfp == NULL) { 1795 res = readtype(tfp, module_name, SHORT_NAME(nme), &type, 2065 (void) fclose(tfp); 2083 (void) fclose(tfp); 3170 FILE *tfp; local 3186 tfp = validmod(module, &openerr); 3187 if (tfp == NULL) { 3221 ret = readtype(tfp, modul 5048 read_mapped_values( FILE *tfp, nvlist_t **nvlp, char *module, char *mapped_list, int value) argument 5402 read_perm_items( int perm_filters, FILE *tfp, char *module_name, char ***perm_items, int *nitems) argument 5515 readtype( FILE *tfp, char *module_name, char *name, ipqos_nvtype_t *type, str_val_nd_t **enum_nvps, char *dfltst, boolean_t allow_ipgpc_priv, place_t *place) argument 5699 readnvpair( FILE *cfp, FILE *tfp, nvlist_t **nvlp, nvpair_t **nvp, ipqos_nvtype_t *type, place_t place, char *module_name) argument 6140 readparams( FILE *cfp, FILE *tfp, char *module_name, ipqos_conf_params_t *params) argument 7301 readfilter( FILE *cfp, FILE *tfp, char *module_name, ipqos_conf_filter_t **filter, char **perm_filters, int num_perm_filters) argument 7785 FILE *tfp = NULL; local 8543 FILE *tfp; local 8757 FILE *tfp; local [all...] |