chiark / gitweb /
hwdb: FOREACH_HWDB_PROPERTY -> SD_HWDB_FOREACH_PROPERTY
authorDavid Herrmann <dh.herrmann@gmail.com>
Fri, 12 Dec 2014 08:30:50 +0000 (09:30 +0100)
committerDavid Herrmann <dh.herrmann@gmail.com>
Fri, 12 Dec 2014 08:30:50 +0000 (09:30 +0100)
Lets not pollute the global namespace. Prefix all our exported names and
macros with SD_HWDB_*.

src/libudev/libudev-hwdb.c
src/systemd/sd-hwdb.h

index 7a21b3d3ee7c5d45b6ec095813f4d9b7aca312e9..2e198f20499aa27bd88fb204ff12212e34e094d7 100644 (file)
@@ -140,7 +140,7 @@ _public_ struct udev_list_entry *udev_hwdb_get_properties_list_entry(struct udev
 
         udev_list_cleanup(&hwdb->properties_list);
 
 
         udev_list_cleanup(&hwdb->properties_list);
 
-        FOREACH_HWDB_PROPERTY(hwdb->hwdb, modalias, key, value) {
+        SD_HWDB_FOREACH_PROPERTY(hwdb->hwdb, modalias, key, value) {
                 if (udev_list_entry_add(&hwdb->properties_list, key, value) == NULL) {
                         errno = ENOMEM;
                         return NULL;
                 if (udev_list_entry_add(&hwdb->properties_list, key, value) == NULL) {
                         errno = ENOMEM;
                         return NULL;
index fae9b9fd4bde497b831ce1161e36dea4e935ad27..f41555df7efa8d05e6f4973f661be9251d24a740 100644 (file)
@@ -39,7 +39,7 @@ int sd_hwdb_get(sd_hwdb *hwdb, const char *modalias, const char *key, const char
 int sd_hwdb_seek(sd_hwdb *hwdb, const char *modalias);
 int sd_hwdb_enumerate(sd_hwdb *hwdb, const char **key, const char **value);
 
 int sd_hwdb_seek(sd_hwdb *hwdb, const char *modalias);
 int sd_hwdb_enumerate(sd_hwdb *hwdb, const char **key, const char **value);
 
-#define FOREACH_HWDB_PROPERTY(hwdb, modalias, key, value)               \
+#define SD_HWDB_FOREACH_PROPERTY(hwdb, modalias, key, value)            \
         if (sd_hwdb_seek(hwdb, modalias) >= 0)                          \
                 while (sd_hwdb_enumerate(hwdb, &(key), &(value)) > 0)
 
         if (sd_hwdb_seek(hwdb, modalias) >= 0)                          \
                 while (sd_hwdb_enumerate(hwdb, &(key), &(value)) > 0)