chiark / gitweb /
[PATCH] pass SEQNUM trough udevd
[elogind.git] / udev_lib.h
index cc264fa9b4ce27f9ebd496483d053aee4e1b1ae4..53ad92d505443b584567fbeca8118bdef9662c45 100644 (file)
@@ -59,6 +59,12 @@ do { \
        snprintf((to) + strlen(to), maxsize - strlen(to)-1, "%u", i); \
 } while (0)
 
+#define strlongcat(to, i) \
+do { \
+       to[sizeof(to)-1] = '\0'; \
+       snprintf((to) + strlen(to), sizeof(to) - strlen(to)-1, "%li", i); \
+} while (0)
+
 #define foreach_strpart(str, separator, pos, len) \
        for(pos = str, len = 0; \
            (pos) < ((str) + strlen(str)); \
@@ -75,6 +81,8 @@ extern char get_device_type(const char *path, const char *subsystem);
 extern int file_map(const char *filename, char **buf, size_t *bufsize);
 extern void file_unmap(char *buf, size_t bufsize);
 extern size_t buf_get_line(char *buf, size_t buflen, size_t cur);
+extern void leading_slash(char *path);
+extern void no_leading_slash(char *path);
 extern int  call_foreach_file(int fnct(char *f) , char *filename, char *extension);