summaryrefslogtreecommitdiff
path: root/udev/lib
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2008-09-10 21:50:21 +0200
committerKay Sievers <kay.sievers@vrfy.org>2008-09-10 21:50:21 +0200
commit17fcfb5972977b6a3aedca6ad2aa8d1fbfbc761d (patch)
tree829107a8a24b59948c67d0877990e39cbf1c32ce /udev/lib
parent31c1f537450e96f8ddd6a0fad2adaefe57996f03 (diff)
use size definitions from libudev
Diffstat (limited to 'udev/lib')
-rw-r--r--udev/lib/libudev-device.c6
-rw-r--r--udev/lib/libudev-private.h3
2 files changed, 5 insertions, 4 deletions
diff --git a/udev/lib/libudev-device.c b/udev/lib/libudev-device.c
index a182750e61..0405e1c98a 100644
--- a/udev/lib/libudev-device.c
+++ b/udev/lib/libudev-device.c
@@ -332,7 +332,7 @@ const char *udev_device_get_devname(struct udev_device *udev_device)
**/
const char *udev_device_get_subsystem(struct udev_device *udev_device)
{
- char subsystem[UTIL_PATH_SIZE];
+ char subsystem[UTIL_NAME_SIZE];
if (udev_device == NULL)
return NULL;
@@ -398,7 +398,7 @@ int udev_device_get_properties(struct udev_device *udev_device,
if (udev_device == NULL)
return -1;
list_for_each_entry(name_loop, &udev_device->env_list, node) {
- char name[UTIL_PATH_SIZE];
+ char name[UTIL_NAME_SIZE];
char *val;
strncpy(name, name_loop->name, sizeof(name));
@@ -416,7 +416,7 @@ int udev_device_get_properties(struct udev_device *udev_device,
const char *udev_device_get_driver(struct udev_device *udev_device)
{
- char driver[UTIL_PATH_SIZE];
+ char driver[UTIL_NAME_SIZE];
if (udev_device == NULL)
return NULL;
diff --git a/udev/lib/libudev-private.h b/udev/lib/libudev-private.h
index 1f4abc07ba..8ca441639f 100644
--- a/udev/lib/libudev-private.h
+++ b/udev/lib/libudev-private.h
@@ -105,7 +105,8 @@ extern int udev_ctrl_get_set_max_childs(struct udev_ctrl_msg *ctrl_msg);
/* libudev-utils */
#define UTIL_PATH_SIZE 1024
-#define UTIL_LINE_SIZE 1024
+#define UTIL_LINE_SIZE 2048
+#define UTIL_NAME_SIZE 512
struct util_name_entry {
struct list_head node;
char *name;