cur += count+1;
lineno++;
- if (count >= sizeof(line)) {
- err("line too long, conf line skipped %s, line %d", udev_config_filename, lineno);
- continue;
- }
-
/* eat the whitespace */
while ((count > 0) && isspace(bufline[0])) {
bufline++;
if (bufline[0] == COMMENT_CHARACTER)
continue;
+ if (count >= sizeof(line)) {
+ err("line too long, conf line skipped %s, line %d", udev_config_filename, lineno);
+ continue;
+ }
+
memcpy(line, bufline, count);
line[count] = '\0';
cur += count+1;
lineno++;
- if (count >= sizeof(line)) {
- err("line too long, conf line skipped %s, line %d", udev_config_filename, lineno);
- continue;
- }
-
/* eat the whitespace */
while ((count > 0) && isspace(bufline[0])) {
bufline++;
if (bufline[0] == COMMENT_CHARACTER)
continue;
+ if (count >= sizeof(line)) {
+ err("line too long, conf line skipped %s, line %d", udev_config_filename, lineno);
+ continue;
+ }
+
memcpy(line, bufline, count);
line[count] = '\0';