ReactOS 0.4.16-dev-2110-ge3521eb
rpcent.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  rpcent
 

Functions

__BEGIN_DECLS void setrpcent (int) __THROW
 
void endrpcent (void) __THROW
 

Function Documentation

◆ endrpcent()

void endrpcent ( void  )

Definition at line 188 of file getrpcent.c.

189{
190 struct rpcdata *d = _rpcdata();
191
192 if (d == 0)
193 return;
194#ifdef YP
195 if (!__yp_nomap && _yp_check(NULL)) {
196 if (d->current && !d->stayopen)
197 free(d->current);
198 d->current = NULL;
199 d->currentlen = 0;
200 return;
201 }
202 __yp_nomap = 0;
203#endif /* YP */
204 if (d->rpcf && !d->stayopen) {
205 fclose(d->rpcf);
206 d->rpcf = NULL;
207 }
208}
#define free
Definition: debug_ros.c:5
#define NULL
Definition: types.h:112
int CDECL fclose(FILE *file)
Definition: file.c:3757
static struct rpcdata * _rpcdata(void)
Definition: getrpcent.c:80
#define d
Definition: ke_i.h:81

◆ setrpcent()

__BEGIN_DECLS void setrpcent ( int  f)

Definition at line 163 of file getrpcent.c.

165{
166 struct rpcdata *d = _rpcdata();
167
168 if (d == 0)
169 return;
170#ifdef YP
171 if (!__yp_nomap && _yp_check(NULL)) {
172 if (d->current)
173 free(d->current);
174 d->current = NULL;
175 d->currentlen = 0;
176 return;
177 }
178 __yp_nomap = 0;
179#endif /* YP */
180 if (d->rpcf == NULL)
181 d->rpcf = fopen(RPCDB, "r");
182 else
183 rewind(d->rpcf);
184 d->stayopen |= f;
185}
FILE *CDECL fopen(const char *path, const char *mode)
Definition: file.c:4310
void CDECL rewind(FILE *file)
Definition: file.c:1712
#define RPCDB
Definition: getrpcent.c:75
#define f
Definition: ke_i.h:83