diff options
author | Kirill Ponomarev <krion@FreeBSD.org> | 2017-02-09 17:50:06 +0000 |
---|---|---|
committer | Kirill Ponomarev <krion@FreeBSD.org> | 2017-02-09 17:50:06 +0000 |
commit | 19a4f0ddb2cb35202cb7fb2d1b30b3401bce9052 (patch) | |
tree | 6da50c555bcccbe0eccec3a12762bf36935b4119 /comms/rxtx/files/patch-src-gnu-io-RXTXCommDriver.java | |
parent | Update net-mgmt/prometheus to 1.5.1 (diff) |
- Added LICENSE
- Fixed patches for portlint
- Supressed debug message on RXTXPort:removeEventListener:Exit when not in debug mode
- Added java bootstrap class
- Updated java source/target directives which will be depreciated in future release, see http://openjdk.java.net/
+jeps/182, and regression tested functionality.
PR: 216248
Submitted by: james@elstone.net
Approved by: mat (mentor)
Differential Revision: https://reviews.freebsd.org/D9508
Notes
Notes:
svn path=/head/; revision=433756
Diffstat (limited to '')
-rw-r--r-- | comms/rxtx/files/patch-src-gnu-io-RXTXCommDriver.java | 84 |
1 files changed, 41 insertions, 43 deletions
diff --git a/comms/rxtx/files/patch-src-gnu-io-RXTXCommDriver.java b/comms/rxtx/files/patch-src-gnu-io-RXTXCommDriver.java index d7b055f1fe42..f3ca672f6291 100644 --- a/comms/rxtx/files/patch-src-gnu-io-RXTXCommDriver.java +++ b/comms/rxtx/files/patch-src-gnu-io-RXTXCommDriver.java @@ -1,5 +1,5 @@ ---- src/gnu/io/RXTXCommDriver.java.orig 2008-11-14 00:44:01.000000000 +0000 -+++ src/gnu/io/RXTXCommDriver.java 2015-05-11 16:51:34.000000000 +0100 +--- src/gnu/io/RXTXCommDriver.java.orig 2008-11-14 00:44:01 UTC ++++ src/gnu/io/RXTXCommDriver.java @@ -56,10 +56,15 @@ | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | All trademarks belong to their respective owners. @@ -20,7 +20,7 @@ package gnu.io; -@@ -69,132 +74,196 @@ +@@ -69,132 +74,196 @@ import java.io.*; import java.util.StringTokenizer; /** @@ -73,12 +73,12 @@ - } catch ( Error UnsatisfiedLinkError ) + + try -+ { + { +- // for rxtx prior to 2.1.7 + LibVersion = RXTXVersion.nativeGetVersion(); + } + catch ( Error UnsatisfiedLinkError ) - { -- // for rxtx prior to 2.1.7 ++ { + + /** + * for rxtx prior to 2.1.7 @@ -278,7 +278,7 @@ for( p[0] =97 ;p[0] < 123; p[0]++ ) { if (testRead(PortName.concat(new String(p)),PortType)) -@@ -206,7 +275,11 @@ +@@ -206,7 +275,11 @@ public class RXTXCommDriver implements C ); } } @@ -291,7 +291,7 @@ for( p[0] =48 ;p[0] <= 57; p[0]++ ) { if (testRead(PortName.concat(new String(p)),PortType)) -@@ -218,73 +291,109 @@ +@@ -218,73 +291,109 @@ public class RXTXCommDriver implements C ); } } @@ -450,7 +450,7 @@ if(osName.toLowerCase().indexOf("windows") == -1 ) { PortName = deviceDirectory + C; -@@ -293,85 +402,136 @@ +@@ -293,85 +402,136 @@ public class RXTXCommDriver implements C { PortName = C; } @@ -633,7 +633,7 @@ while (tok.hasMoreElements()) { String PortName = tok.nextToken(); -@@ -380,94 +540,186 @@ +@@ -380,94 +540,186 @@ public class RXTXCommDriver implements C CommPortIdentifier.addPortName(PortName, PortType, this); } @@ -880,7 +880,7 @@ CandidateDeviceNames=temp; } else if(osName.toLowerCase().indexOf("windows") != -1 ) -@@ -482,329 +734,338 @@ +@@ -482,329 +734,338 @@ public class RXTXCommDriver implements C temp[i + 255] = "LPT" + i; } CandidateDeviceNames=temp; @@ -930,34 +930,6 @@ + * + * The uucp lock files should not cause problems. */ -- -- String term[] = new String[2]; -- int l = 0; -- File dev = null; -- -- dev = new File( "/dev/term" ); -- if( dev.list().length > 0 ) -- term[l++] ="term/"; -- /* -- dev = new File( "/dev/cua0" ); -- if( dev.list().length > 0 ) -- term[l++] = "cua/"; -- */ -- String[] temp = new String[l]; -- for(l--;l >= 0;l--) -- temp[l] = term[l]; -- CandidateDeviceNames=temp; -- } -- else -- { -- File dev = new File( deviceDirectory ); -- String[] temp = dev.list(); -- CandidateDeviceNames=temp; -- } -- if (CandidateDeviceNames==null) -- { -- if (debug) -- System.out.println("RXTXCommDriver:registerScannedPorts() no Device files to check "); + + /** + * File dev = new File( "/dev/term" ); @@ -978,7 +950,10 @@ + * } + * CandidateDeviceNames=temp; + **/ -+ + +- String term[] = new String[2]; +- int l = 0; +- File dev = null; + /** + * ok.. Look the the dirctories representing the port + * kernel driver interface. @@ -986,7 +961,30 @@ + * If there are entries there are possibly ports we can + * use and need to enumerate. + **/ -+ + +- dev = new File( "/dev/term" ); +- if( dev.list().length > 0 ) +- term[l++] ="term/"; +- /* +- dev = new File( "/dev/cua0" ); +- if( dev.list().length > 0 ) +- term[l++] = "cua/"; +- */ +- String[] temp = new String[l]; +- for(l--;l >= 0;l--) +- temp[l] = term[l]; +- CandidateDeviceNames=temp; +- } +- else +- { +- File dev = new File( deviceDirectory ); +- String[] temp = dev.list(); +- CandidateDeviceNames=temp; +- } +- if (CandidateDeviceNames==null) +- { +- if (debug) +- System.out.println("RXTXCommDriver:registerScannedPorts() no Device files to check "); + String term[] = new String[2]; + int l = 0; + File dev = null; @@ -1523,7 +1521,7 @@ }; CandidatePortPrefixes=temp; } -@@ -827,37 +1088,51 @@ +@@ -827,37 +1088,51 @@ public class RXTXCommDriver implements C String [] temp={}; CandidatePortPrefixes=temp; } @@ -1595,7 +1593,7 @@ return new RXTXPort( PortName ); } else -@@ -868,18 +1143,30 @@ +@@ -868,18 +1143,30 @@ public class RXTXCommDriver implements C return new LPRPort( PortName ); default: if (debug) |