static byte[] cloneByteArray(byte[] a) { if (a == null) null; byte[] b = new[a.length]; System.arraycopy(a, 0, b, 0, a.length); ret b; }