Camel
  1. Camel
  2. CAMEL-4477

parseURI in org.apache.camel.component.printer.PrinterConfiguration leaves a prefixed "/" on the printername attribute which should be removed

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.8.1
    • Fix Version/s: 2.7.4, 2.8.2, 2.9.0
    • Component/s: camel-printer
    • Labels:
      None
    • Environment:

      Windows 7 64-bit, jdk 1.6.0_20

    • Estimated Complexity:
      Novice

      Description

      in PrinterConfiguration.parseURI(), the line:

      setPrintername(uri.getPath());

      ends up leaving the starting "/" which is not really a part of the printer's name. When the PrinterProducer later searches for the matching PrintService, it attempts to recreate the printer path from the host name and the printer name with the following:

      setPrinter("\\\\" + config.getHostname() + "
      " + config.getPrintername());

      which ends up with a string like: \\<HostName>\/<printer> because the leading "/" was not removed from the printer name, and which leads to the printer never being found.

        Activity

          People

          • Assignee:
            Claus Ibsen
            Reporter:
            Denis Robert
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development