[haiku-commits] r40278 - haiku/trunk/src/add-ons/print/transports/hp_jetdirect

  • From: michael.w.pfeiffer@xxxxxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Mon, 24 Jan 2011 21:01:31 +0100 (CET)

Author: laplace
Date: 2011-01-24 21:01:31 +0100 (Mon, 24 Jan 2011)
New Revision: 40278
Changeset: http://dev.haiku-os.org/changeset/40278

Modified:
   
haiku/trunk/src/add-ons/print/transports/hp_jetdirect/HPJetDirectTransport.cpp
Log:
Fixed off by one error. The port number should now be taken from the
URL.


Modified: 
haiku/trunk/src/add-ons/print/transports/hp_jetdirect/HPJetDirectTransport.cpp
===================================================================
--- 
haiku/trunk/src/add-ons/print/transports/hp_jetdirect/HPJetDirectTransport.cpp  
    2011-01-23 23:12:26 UTC (rev 40277)
+++ 
haiku/trunk/src/add-ons/print/transports/hp_jetdirect/HPJetDirectTransport.cpp  
    2011-01-24 20:01:31 UTC (rev 40278)
@@ -43,7 +43,7 @@
 
        int32 index = address.FindLast(':');
        if (index >= 0) {
-               fPort = atoi(address.String() + index);
+               fPort = atoi(address.String() + index + 1);
                address.MoveInto(fHost, 0, index);
        } else
                fHost = address;


Other related posts: