diff options
author | Theodore Tso <tytso@mit.edu> | 1998-11-17 22:38:20 +0000 |
---|---|---|
committer | Theodore Tso <tytso@mit.edu> | 1998-11-17 22:38:20 +0000 |
commit | be4847fe057db23d0412faca6614227fb5c01a9f (patch) | |
tree | 8e0dd573c1a635a47cea9a224267a2c137fe2329 /src/util | |
parent | 3523c3942b0d0ea73ff51b3f3fdd05f9e030b5f6 (diff) | |
download | krb5-be4847fe057db23d0412faca6614227fb5c01a9f.tar.gz krb5-be4847fe057db23d0412faca6614227fb5c01a9f.tar.xz krb5-be4847fe057db23d0412faca6614227fb5c01a9f.zip |
prof_get.c (profile_get_values): If there are no relations found,
return PROF_NO_RELATION, instead of an empty list.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@11043 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/profile/ChangeLog | 5 | ||||
-rw-r--r-- | src/util/profile/prof_get.c | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/src/util/profile/ChangeLog b/src/util/profile/ChangeLog index 21dd99016d..a0a48dad3e 100644 --- a/src/util/profile/ChangeLog +++ b/src/util/profile/ChangeLog @@ -1,3 +1,8 @@ +1998-11-17 Theodore Ts'o <tytso@rsts-11.mit.edu> + + * prof_get.c (profile_get_values): If there are no relations + found, return PROF_NO_RELATION, instead of an empty list. + 1998-11-13 Theodore Ts'o <tytso@rsts-11.mit.edu> * Makefile.in: Set the myfulldir and mydir variables (which are diff --git a/src/util/profile/prof_get.c b/src/util/profile/prof_get.c index 2613127b7e..7f1d3c5ce4 100644 --- a/src/util/profile/prof_get.c +++ b/src/util/profile/prof_get.c @@ -162,6 +162,11 @@ profile_get_values(profile, names, ret_values) add_to_list(&values, value); } while (state); + if (values.num == 0) { + retval = PROF_NO_RELATION; + goto cleanup; + } + end_list(&values, ret_values); return 0; |