diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2012-12-18 13:13:40 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2012-12-18 13:13:40 +0000 |
commit | 3f796fcf771107bd9f0823dcc96ac6dc0db37074 (patch) | |
tree | 6161bb5da082c955423a4b8ce3a8dd6eac24a687 /src/ats/ats_api_performance.c | |
parent | 349c2db632fa4969ee11d4d0bfb2cab78d5051b8 (diff) | |
download | gnunet-3f796fcf771107bd9f0823dcc96ac6dc0db37074.tar.gz gnunet-3f796fcf771107bd9f0823dcc96ac6dc0db37074.zip |
- preference mgmt
Diffstat (limited to 'src/ats/ats_api_performance.c')
-rw-r--r-- | src/ats/ats_api_performance.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/ats/ats_api_performance.c b/src/ats/ats_api_performance.c index 5cb199266..25b492614 100644 --- a/src/ats/ats_api_performance.c +++ b/src/ats/ats_api_performance.c | |||
@@ -830,6 +830,22 @@ GNUNET_ATS_performance_list_addresses_cancel (struct GNUNET_ATS_AddressListHandl | |||
830 | 830 | ||
831 | 831 | ||
832 | /** | 832 | /** |
833 | * Convert a GNUNET_ATS_PreferenceType to a string | ||
834 | * | ||
835 | * @param type the preference type | ||
836 | * @return a string or NULL if invalid | ||
837 | */ | ||
838 | const char * | ||
839 | GNUNET_ATS_print_preference_type (uint32_t type) | ||
840 | { | ||
841 | char *prefs[GNUNET_ATS_PreferenceCount] = GNUNET_ATS_PreferenceTypeString; | ||
842 | if (type < GNUNET_ATS_PreferenceCount) | ||
843 | return prefs[type]; | ||
844 | return NULL; | ||
845 | } | ||
846 | |||
847 | |||
848 | /** | ||
833 | * Change preferences for the given peer. Preference changes are forgotten if peers | 849 | * Change preferences for the given peer. Preference changes are forgotten if peers |
834 | * disconnect. | 850 | * disconnect. |
835 | * | 851 | * |