summaryrefslogtreecommitdiffstats
path: root/src/uca.c
diff options
context:
space:
mode:
authorMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2011-04-11 16:00:09 +0200
committerMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2011-04-11 16:00:09 +0200
commita7faef63d55ba76fd8bd0f6ae6c403f94e3fe58c (patch)
tree6802c5c1df3217b7ee2c8999257a968dc6b51666 /src/uca.c
parentff329303fc00a8f759c87b227779c39c874c9b9d (diff)
downloaduca-a7faef63d55ba76fd8bd0f6ae6c403f94e3fe58c.tar.gz
uca-a7faef63d55ba76fd8bd0f6ae6c403f94e3fe58c.tar.bz2
uca-a7faef63d55ba76fd8bd0f6ae6c403f94e3fe58c.tar.xz
uca-a7faef63d55ba76fd8bd0f6ae6c403f94e3fe58c.zip
Move definitions out of structure
Diffstat (limited to 'src/uca.c')
-rw-r--r--src/uca.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/uca.c b/src/uca.c
index d6d2faf..7b6cef4 100644
--- a/src/uca.c
+++ b/src/uca.c
@@ -208,12 +208,14 @@ void uca_destroy(struct uca *u)
uca_unlock();
}
-enum uca_property_ids uca_get_property_id(const char *property_name)
+uint32_t uca_get_property_id(const char *property_name, enum uca_property_ids *prop_id)
{
int i = 0;
while (property_map[i].name != NULL) {
- if (!strcmp(property_map[i].name, property_name))
- return i;
+ if (!strcmp(property_map[i].name, property_name)) {
+ *prop_id = (enum uca_property_ids) i;
+ return UCA_NO_ERROR;
+ }
i++;
}
return UCA_ERR_CAMERA | UCA_ERR_PROP | UCA_ERR_INVALID;