hi friends,
i am new to linux . so i am not so familiar with patch applying in source ...
i compiled my sysfsutils-2.1.0 source successfully but the problem is that i need to apply to patch in its source file ...
the two patches they mention is
--- sysfsutils-0_2_0/lib/sysfs_device.c.orig 2003-10-17 11:25:37.000000000 -0
700
+++ sysfsutils-0_2_0/lib/sysfs_device.c 2003-10-20 12:41:59.000000000 -0700
@@ -80,6 +80,7 @@
errno = EINVAL;
return NULL;
}
+ strcpy(attrname, name);
dlist_for_each_data(dev->directory->attributes, cur,
and
--- sysfs_dir.c.orig 2003-08-29 04:43:27.000000000 -0700
+++ sysfs_dir.c 2003-11-20 11:28:36.000000000 -0800
@@ -274,6 +274,7 @@
errno = EINVAL;
return -1;
}
+ attr->value = malloc(sizeof(value));
strncpy(attr->value,value,sizeof(value));
if ((sysfs_write_attribute(attr) != 0 )) {
dprintf("Error write to attribute %s\n", attrpath)
i can edit the lib/sysfs_dir.c and sysfs_device.c but i dont know where to add these lines in the .c file ... where they mentioned the line number i cant get it ..
the link is
http://openhpi.sourceforge.net/manual/x415.html
please help me