Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 45 for overflowed (0.07 sec)

  1. guava/src/com/google/common/math/LongMath.java

       * Math#addExact(long, long)}. Also note that adding two {@code int} values can <b>never</b>
       * overflow a {@code long}, so you can just write {@code (long) a + b}.
       *
       * @throws ArithmeticException if {@code a + b} overflows in signed {@code long} arithmetic
       */
      @InlineMe(replacement = "Math.addExact(a, b)")
      public static long checkedAdd(long a, long b) {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Fri Aug 29 16:20:07 UTC 2025
    - 46.8K bytes
    - Viewed (0)
  2. src/main/java/jcifs/util/InputValidator.java

         *
         * @param a first operand
         * @param b second operand
         * @return sum of a and b
         * @throws ArithmeticException if overflow occurs
         */
        public static int safeAdd(int a, int b) {
            validateIntegerAddition(a, b, "Addition");
            return a + b;
        }
    
        /**
         * Safe integer multiplication with overflow check
         *
         * @param a first operand
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 13.5K bytes
    - Viewed (0)
  3. RELEASE.md

    *   Fixes an overflow producing a crash in `tf.range`
        ([CVE-2021-41202](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-41202))
    *   Fixes an overflow producing a crash in `tf.image.resize` when size is large
        ([CVE-2021-41199](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-41199))
    *   Fixes an overflow producing a crash in `tf.tile` when tiling tensor is large
    Registered: Tue Sep 09 12:39:10 UTC 2025
    - Last Modified: Mon Aug 18 20:54:38 UTC 2025
    - 740K bytes
    - Viewed (1)
  4. src/test/java/jcifs/internal/smb1/com/SmbComQueryInformationResponseTest.java

            long expectedSize = (int) fileSize;
            assertEquals(expectedSize, response.getSize());
        }
    
        @Test
        void testFileSizeOverflow() {
            // Test file size that overflows signed int
            response = new SmbComQueryInformationResponse(mockConfig, 0L);
            setFieldValue(response, "wordCount", 10);
    
            byte[] buffer = new byte[256];
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.9K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/math/LongMathTest.java

                  || !fitsInLong(BigIntegerMath.binomial(LongMath.biggestBinomials[k] + 1, k)));
          // In the first case, any long is valid; in the second, we want to test that the next-bigger
          // long overflows.
        }
        int k = LongMath.biggestBinomials.length;
        assertFalse(fitsInLong(BigIntegerMath.binomial(2 * k, k)));
        // 2 * k is the smallest value for which we don't replace k with (n-k).
      }
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Aug 11 19:31:30 UTC 2025
    - 31.4K bytes
    - Viewed (0)
  6. src/test/java/jcifs/internal/smb2/nego/Smb2NegotiateResponseInputValidationTest.java

    import jcifs.internal.util.SMBUtil;
    
    /**
     * Security-focused test cases for Smb2NegotiateResponse input validation.
     * Tests various malformed input scenarios to ensure proper validation and
     * protection against buffer overflow, integer overflow, and other attacks.
     */
    public class Smb2NegotiateResponseInputValidationTest {
    
        private Configuration mockConfig;
        private Smb2NegotiateResponse response;
    
        @BeforeEach
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 15.8K bytes
    - Viewed (0)
  7. src/main/java/jcifs/util/ServerResponseValidator.java

                integerOverflowsPrevented.incrementAndGet();
                log.warn("Integer overflow in addition: {} + {} = {}", a, b, result);
                throw new SmbException("Integer overflow detected");
            }
            return (int) result;
        }
    
        /**
         * Safely multiply integers checking for overflow
         *
         * @param a first value
         * @param b second value
         * @return product
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 16.6K bytes
    - Viewed (0)
  8. src/main/java/jcifs/internal/smb2/rdma/RdmaErrorHandler.java

                try {
                    // Exponential backoff with overflow protection - ensure safe calculation
                    if (retryDelayMs > 0) {
                        // Safe calculation preventing overflow: use Math.max(0, retryCount - 1) and limit shift
                        int safeShift = Math.min(MAX_BACKOFF_SHIFT, Math.max(0, retryCount - 1));
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 10.5K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/math/IntMathTest.java

                  || !fitsInInt(BigIntegerMath.binomial(IntMath.biggestBinomials[k] + 1, k)));
          // In the first case, any int is valid; in the second, we want to test that the next-bigger
          // int overflows.
        }
        assertFalse(
            fitsInInt(
                BigIntegerMath.binomial(
                    2 * IntMath.biggestBinomials.length, IntMath.biggestBinomials.length)));
      }
    
      @GwtIncompatible // sqrt
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Mon Aug 11 19:31:30 UTC 2025
    - 24.1K bytes
    - Viewed (0)
  10. src/test/java/jcifs/dcerpc/ndr/NdrShortTest.java

                verifyNoMoreInteractions(mockBuffer);
            }
    
            @Test
            @DisplayName("Should encode masked overflow value correctly")
            void testEncodeMaskedValue() throws NdrException {
                // Given: NdrShort with overflow value that gets masked
                int inputValue = 300; // 300 & 0xFF = 44
                NdrShort ndrShort = new NdrShort(inputValue);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.2K bytes
    - Viewed (0)
Back to top