1dirfile_free_entry_strings(3)       GETDATA      dirfile_free_entry_strings(3)
2
3
4

NAME

6       dirfile_free_entry_strings  —  free  strings  in  a  GetData gd_entry_t
7       object
8

SYNOPSIS

10       #include <getdata.h>
11
12       gd_entry_t *dirfile_free_entry_strings(gd_entry_t *entry);
13

DESCRIPTION

15       The dirfile_free_entry_strings() function frees the  character  strings
16       found in the gd_entry_t object entry which were previously allocated by
17       a call to get_entry(3).  If entry is NULL, this function does nothing.
18
19       If non-NULL, entry must point  to  a  valid  and  properly  initialised
20       gd_entry_t object, such as that returned by get_entry(3).  As well, the
21       caller may construct a properly initialised gd_entry_t object by  first
22       setting  all bits to zero, then setting the field_type parameter to the
23       desired gd_entype_t symbol, and finally initialising only  the  members
24       defined  for that type.  The results of calling this function are unde‐
25       fined if the character strings pointed to by the string members of  en‐
26       try  have  not been allocated with malloc(3), unless these pointer mem‐
27       bers are equal to NULL.
28
29       See get_entry(3) for a complete  description  of  the  gd_entry_t  data
30       type.
31

RETURN VALUE

33       A call to dirfile_free_entry_strings() always returns its input, entry.
34

NOTES

36       This  function  is  provided  as  a convenience only.  Callers may free
37       strings allocated by get_entry(3) themselves by simply calling  free(3)
38       on  the appropriate members for the given entry type, if they prefer to
39       do so.
40

SEE ALSO

42       get_entry(3), free(3)
43
44
45
46Version 0.4.0                   17 October 2008  dirfile_free_entry_strings(3)
Impressum