Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for getOEMBytes (0.18 sec)

  1. src/main/java/jcifs/netbios/Name.java

        }
    
        int writeWireFormat(final byte[] dst, final int dstIndex) {
            // write 0x20 in first byte
            dst[dstIndex] = 0x20;
    
            final byte tmp[] = Strings.getOEMBytes(this.name, this.config);
            int i;
            for (i = 0; i < tmp.length; i++) {
                dst[dstIndex + 2 * i + 1] = (byte) (((tmp[i] & 0xF0) >> 4) + 0x41);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 8K bytes
    - Viewed (0)
  2. src/main/java/jcifs/util/Strings.java

         *
         * @param str the string to encode
         * @param config the configuration providing the OEM encoding
         * @return the string as bytes
         */
        public static byte[] getOEMBytes(final String str, final Configuration config) {
            if (str == null) {
                return new byte[0];
            }
            try {
                return str.getBytes(config.getOemEncoding());
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 6.5K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/smb1/com/SmbComQueryInformationTest.java

        }
    
        @Test
        @DisplayName("writeBytesWireFormat with null path returns minimal bytes")
        void testWriteWhenPathIsNull() {
            // When path is null, Strings.getOEMBytes returns empty array, not NPE
            when(mockConfig.getOemEncoding()).thenReturn("windows-1252");
            SmbComQueryInformation nullPathCmd = new SmbComQueryInformation(mockConfig, null);
            byte[] buffer = new byte[50];
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 4.9K bytes
    - Viewed (0)
Back to top