Branch oldpackages for 14.07
[14.07/packages.git] / libs / libinklevel / patches / 003-fix_usb_device_location.patch
1 --- a/linux.c
2 +++ b/linux.c
3 @@ -82,7 +82,7 @@ int get_device_id(const int port, const 
4    if (port == USB || port == CUSTOM_USB) {
5  
6      if (port == USB) {
7 -      sprintf(device_file1, "/dev/usb/lp%d", portnumber);
8 +      sprintf(device_file1, "/dev/lp%d", portnumber);
9        sprintf(device_file2, "/dev/usblp%d", portnumber);
10        fd = open(device_file1, O_RDONLY);
11        if (fd == -1) {
12 @@ -142,7 +142,7 @@ int open_printer_device(const int port, 
13    int fd;
14  
15    if (port == USB) {
16 -    sprintf(device_file1, "/dev/usb/lp%d", portnumber);
17 +    sprintf(device_file1, "/dev/lp%d", portnumber);
18      sprintf(device_file2, "/dev/usblp%d", portnumber);
19  #ifdef WITH_PARPORT
20    } else if (port == PARPORT) {