Add profile_free_string to free strings allocated by profile_get_string
authorDanilo Almeida <dalmeida@mit.edu>
Thu, 5 Aug 1999 19:37:54 +0000 (19:37 +0000)
committerDanilo Almeida <dalmeida@mit.edu>
Thu, 5 Aug 1999 19:37:54 +0000 (19:37 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@11622 dc483132-0cff-0310-8789-dd5450dbe970

src/util/profile/ChangeLog
src/util/profile/prof_get.c
src/util/profile/profile.hin

index 9366adfd8beb05339153b1df42f4bbb9135d478d..46c888b51fd3e9a02a0d29fcf60f8504442ece07 100644 (file)
@@ -1,3 +1,9 @@
+1999-08-05  Danilo Almeida  <dalmeida@mit.edu>
+
+       * prof_get.c (profile_free_string): 
+       * profile.hin: Add profile_free_string to free strings allocated
+       by profile_get_string.
+
 1999-08-03 Alexandra Ellwood <lxs@mit.edu>
 
        * prof_file.c (profile_open_file)
index 2589b24e4b8efe5e504f32666cd3bca581a246df..2c08c204991284019b31bbe6a114ed0a5994f772 100644 (file)
@@ -241,6 +241,14 @@ profile_get_string(profile, name, subname, subsubname,
        return 0;
 }
 
+KRB5_DLLIMP void KRB5_CALLCONV
+profile_free_string(value)
+       char    *value;
+{
+       if (value)
+               free(value);
+}
+
 KRB5_DLLIMP errcode_t KRB5_CALLCONV
 profile_get_integer(profile, name, subname, subsubname,
                              def_val, ret_int)
index 420b955d4b94b6a539a3263d00bf05cfac927f86..177e213f9bd16fd08123f5faca86df1410d9ddc2 100644 (file)
@@ -86,6 +86,10 @@ KRB5_DLLIMP long KRB5_CALLCONV profile_get_string
        PROTOTYPE((profile_t profile, const char *name, const char *subname, 
                        const char *subsubname, const char *def_val,
                        char **ret_string));
+
+KRB5_DLLIMP void KRB5_CALLCONV profile_free_string
+       PROTOTYPE ((char *value));
+
 KRB5_DLLIMP long KRB5_CALLCONV profile_get_integer
        PROTOTYPE((profile_t profile, const char *name, const char *subname,
                        const char *subsubname, int def_val,