Lines Matching refs:lep

71 	struct logtab_ent *lep = NULL;  in logtab_getent()  local
74 if ((lep = (struct logtab_ent *)malloc(sizeof (*lep))) == NULL) { in logtab_getent()
77 (void) memset((char *)lep, 0, sizeof (*lep)); in logtab_getent()
91 if ((lep->le_buffer = strdup(tmp)) == NULL) { in logtab_getent()
101 if ((lep->le_path = strdup(tmp)) == NULL) { in logtab_getent()
111 if ((lep->le_tag = strdup(tmp)) == NULL) { in logtab_getent()
121 lep->le_state = atoi(tmp); in logtab_getent()
123 *lepp = lep; in logtab_getent()
127 logtab_ent_free(lep); in logtab_getent()
136 logtab_putent(FILE *fd, struct logtab_ent *lep) in logtab_putent() argument
144 lep->le_buffer, in logtab_putent()
145 lep->le_path, in logtab_putent()
146 lep->le_tag, in logtab_putent()
147 lep->le_state); in logtab_putent()
213 struct logtab_ent *lep; in logtab_rement() local
219 while ((error = logtab_getent(fd, &lep)) > 0) { in logtab_rement()
222 found = strcmp(buffer, lep->le_buffer) == 0; in logtab_rement()
224 found = found && (strcmp(path, lep->le_path) == 0); in logtab_rement()
226 found = found && (strcmp(tag, lep->le_tag) == 0); in logtab_rement()
228 found = found && (state == lep->le_state); in logtab_rement()
231 logtab_ent_free(lep); in logtab_rement()
240 tmpl->lel_le = lep; in logtab_rement()
297 struct logtab_ent *lep; in logtab_deactivate() local
303 while ((error = logtab_getent(fd, &lep)) > 0) { in logtab_deactivate()
306 found = strcmp(buffer, lep->le_buffer) == 0; in logtab_deactivate()
308 found = found && (strcmp(path, lep->le_path) == 0); in logtab_deactivate()
310 found = found && (strcmp(tag, lep->le_tag) == 0); in logtab_deactivate()
311 if (found && (lep->le_state == LES_ACTIVE)) { in logtab_deactivate()
313 lep->le_state = LES_INACTIVE; in logtab_deactivate()
323 lelp->lel_le = lep; in logtab_deactivate()
389 logtab_ent_free(struct logtab_ent *lep) in logtab_ent_free() argument
391 if (lep->le_buffer) in logtab_ent_free()
392 free(lep->le_buffer); in logtab_ent_free()
393 if (lep->le_path) in logtab_ent_free()
394 free(lep->le_path); in logtab_ent_free()
395 if (lep->le_tag) in logtab_ent_free()
396 free(lep->le_tag); in logtab_ent_free()
397 free(lep); in logtab_ent_free()