Changeset 3d4ad475 in mainline
- Timestamp:
- 2012-08-17T17:58:32Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b5f305b
- Parents:
- 1de97fe6
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/isa/isa.c
r1de97fe6 r3d4ad475 308 308 /* Get the name part of the rest of the line. */ 309 309 strtok(line, ":"); 310 311 /* Allocate output buffer. */ 312 size_t size = str_size(line) + 1; 313 char *name = malloc(size); 314 315 if (name != NULL) { 316 /* Copy the result to the output buffer. */ 317 str_cpy(name, size, line); 318 } 319 320 return name; 310 return line; 321 311 } 322 312 … … 524 514 { 525 515 char *line; 526 char *fun_name = NULL;527 516 528 517 /* Skip empty lines. */ … … 538 527 539 528 /* Get device name. */ 540 fun_name = get_device_name(line);529 const char *fun_name = get_device_name(line); 541 530 if (fun_name == NULL) 542 531 return NULL; 543 532 544 533 isa_fun_t *fun = isa_fun_create(isa, fun_name); 545 free(fun_name);546 534 if (fun == NULL) { 547 535 return NULL;
Note:
See TracChangeset
for help on using the changeset viewer.