Lines Matching refs:priv
49 struct mlfiPriv *priv = MLFIPRIV;
54 if (priv == NULL)
58 if (priv->mlfi_fp != NULL && fclose(priv->mlfi_fp) == EOF)
62 (void) unlink(priv->mlfi_fname);
69 p = strrchr(priv->mlfi_fname, '/');
71 p = priv->mlfi_fname;
80 (void) unlink(priv->mlfi_fname);
84 free(priv->mlfi_fname);
85 free(priv);
98 struct mlfiPriv *priv;
102 priv = malloc(sizeof *priv);
103 if (priv == NULL)
108 memset(priv, '\0', sizeof *priv);
111 priv->mlfi_fname = strdup("/tmp/msg.XXXXXXXX");
112 if (priv->mlfi_fname == NULL)
114 free(priv);
117 if ((fd = mkstemp(priv->mlfi_fname)) < 0 ||
118 (priv->mlfi_fp = fdopen(fd, "w+")) == NULL)
122 free(priv->mlfi_fname);
123 free(priv);
128 smfi_setpriv(ctx, priv);