Для получения триального ключа
заполните форму ниже
Team License (базовая версия)
Enterprise License (расширенная версия)
* Нажимая на кнопку, вы даете согласие на обработку
своих персональных данных. См. Политику конфиденциальности

Запросите информацию о ценах
Новая лицензия
Продление лицензии
--Выберите валюту--
USD
EUR
GBP
RUB
* Нажимая на кнопку, вы даете согласие на обработку
своих персональных данных. См. Политику конфиденциальности

Бесплатная лицензия PVS-Studio для специалистов Microsoft MVP
* Нажимая на кнопку, вы даете согласие на обработку
своих персональных данных. См. Политику конфиденциальности

Для получения лицензии для вашего открытого
проекта заполните, пожалуйста, эту форму
* Нажимая на кнопку, вы даете согласие на обработку
своих персональных данных. См. Политику конфиденциальности

Мне интересно попробовать плагин на:
* Нажимая на кнопку, вы даете согласие на обработку
своих персональных данных. См. Политику конфиденциальности

Ваше сообщение отправлено.

Мы ответим вам на


Если вы так и не получили ответ, пожалуйста, проверьте папку
Spam/Junk и нажмите на письме кнопку "Не спам".
Так Вы не пропустите ответы от нашей команды.

>
>
>
Классификация предупреждений PVS-Studio…

Классификация предупреждений PVS-Studio согласно SEI CERT Coding Standard

SEI CERT Coding Standard - набор стандартов написания программного обеспечения (ПО) на языках C, C++, Java и Perl, разрабатываемых координационным центром CERT (CERT Coordination Center, CERT/CC) для повышения надёжности и безопасности ПО.

Страницы PVS-Studio на сайте SEI CERT: C, C++, Java.

C/C++ диагностики

Error Code

Error Description

Mapping

V502

The '?:' operator may not work as expected. The '?:' operator has a lower priority than the 'foo' operator.

EXP00-C

V503

Nonsensical comparison: pointer < 0.

EXP08-C

V505

The 'alloca' function is used inside the loop. This can quickly overflow stack.

MEM05-C

V506

Pointer to local variable 'X' is stored outside the scope of this variable. Such a pointer will become invalid.

DCL30-C

V507

Pointer to local array 'X' is stored outside the scope of this array. Such a pointer will become invalid.

DCL30-C

V509

Exceptions raised inside noexcept functions must be wrapped in a try..catch block.

DCL57-CPP

V510

The 'Foo' function receives class-type variable as 'N'th actual argument. This is unexpected behavior.

FIO47-C

V511

The sizeof() operator returns pointer size instead of array size.

ARR01-C

V512

Call of the 'Foo' function will lead to buffer overflow or underflow.

ARR01-C, ARR30-C

V513

Use _beginthreadex/_endthreadex functions instead of CreateThread/ExitThread functions.

MSC24-C

V514

Potential logical error. Size of a pointer is divided by another value.

ARR01-C

V515

The 'delete' operator is applied to non-pointer.

MEM51-CPP

V516

Non-null function pointer is compared to null. Consider inspecting the expression.

EXP16-C

V517

Potential logical error. The 'if (A) {...} else if (A) {...}' pattern was detected.

MSC01-C

V518

The 'malloc' function allocates suspicious amount of memory calculated by 'strlen(expr)'. Perhaps the correct expression is strlen(expr) + 1.

STR31-C

V519

The 'x' variable is assigned values twice successively. Perhaps this is a mistake.

MSC13-C

V520

Comma operator ',' in array index expression.

EXP08-C

V521

Expressions that use comma operator ',' are dangerous. Make sure the expression is correct.

EXP10-C, EXP50-CPP

V522

Possible null pointer dereference.

EXP34-C, MEM52-CPP

V527

The 'zero' value is assigned to pointer. Probably meant: *ptr = zero.

INT36-C

V528

Pointer is compared with 'zero' value. Probably meant: *ptr != zero.

INT36-C

V529

Suspicious semicolon ';' after 'if/for/while' operator.

EXP15-C

V530

Return value of 'Foo' function is required to be used.

EXP12-C

V531

The sizeof() operator is multiplied by sizeof(). Consider inspecting the expression.

MEM35-C

V532

Consider inspecting the statement of '*pointer++' pattern. Probably meant: '(*pointer)++'.

EXP30-C

V533

It is possible that a wrong variable is incremented inside the 'for' operator. Consider inspecting 'X'.

MSC01-C

V534

It is possible that a wrong variable is compared inside the 'for' operator. Consider inspecting 'X'.

MSC01-C

V535

The 'X' variable is used for this loop and outer loops.

MSC01-C

V536

Constant value is represented by an octal form.

DCL18-C

V539

Iterators are passed as arguments to 'Foo' function. Consider inspecting the expression.

CTR53-CPP

V540

Member 'x' should point to string terminated by two 0 characters.

EXP37-C

V541

String is printed into itself. Consider inspecting the expression.

EXP37-C

V542

Suspicious type cast: 'Type1' to ' Type2'. Consider inspecting the expression.

INT36-C

V546

The 'Foo(Foo)' class member is initialized with itself.

EXP53-CPP

V548

TYPE X[][] is not equivalent to TYPE **X. Consider inspecting type casting.

EXP36-C

V549

The 'first' argument of 'Foo' function is equal to the 'second' argument.

EXP37-C

V550

Suspicious precise comparison. Consider using a comparison with defined precision: fabs(A - B) < Epsilon or fabs(A - B) > Epsilon.

FLP02-C

V551

Unreachable code under a 'case' label.

MSC12-C

V554

Incorrect use of smart pointer.

MEM51-CPP

V555

Expression of the 'A - B > 0' kind will work as 'A != B'.

INT02-C

V556

Values of different enum types are compared.

MSC01-C

V557

Possible array overrun.

ARR30-C

V558

Function returns pointer/reference to temporary local object.

DCL30-C

V559

Suspicious assignment inside the conditional expression of 'if/while/for' statement.

EXP45-C

V561

Consider assigning value to 'foo' variable instead of declaring it anew.

DCL01-C

V562

Bool type value is compared with value of N. Consider inspecting the expression.

INT31-C

V563

An 'else' branch may apply to the previous 'if' statement.

EXP19-C

V564

The '&' or '|' operator is applied to bool type value. Check for missing parentheses or use the '&&' or '||' operator.

EXP46-C

V565

Empty exception handler. Silent suppression of exceptions can hide errors in source code during testing.

ERR56-CPP

V566

Integer constant is converted to pointer. Check for an error or bad coding style.

INT36-C

V567

Modification of variable is unsequenced relative to another operation on the same variable. This may lead to undefined behavior.

EXP30-C

V568

It is suspicious that the argument of sizeof() operator is the expression.

EXP44-C, ARR01-C

V569

Truncation of constant value.

INT31-C

V573

Use of uninitialized variable 'Foo'. The variable was used to initialize itself.

EXP33-C, EXP53-CPP

V574

Pointer is used both as an array and as a pointer to single object.

EXP08-C

V575

Function receives suspicious argument.

EXP37-C

V576

Incorrect format. Consider checking the Nth actual argument of the 'Foo' function.

FIO47-C, DCL11-C

V577

Label is present inside switch(). Check for typos and consider using the 'default:' operator instead.

MSC01-C

V579

The 'Foo' function receives the pointer and its size as arguments. This may be a potential error. Inspect the Nth argument.

ARR01-C

V580

Suspicious explicit type casting. Consider inspecting the expression.

EXP39-C

V582

Consider reviewing the source code that uses the container.

ARR30-C

V585

Attempt to release memory that stores the 'Foo' local variable.

MEM34-C

V586

The 'Foo' function is called twice to deallocate the same resource.

MEM30-C, MEM50-CPP

V590

Possible excessive expression or typo. Consider inspecting the expression.

MSC01-C

V591

Non-void function must return value.

MSC52-CPP

V593

Expression 'A = B == C' is calculated as 'A = (B == C)'. Consider inspecting the expression.

EXP00-C

V594

Pointer to array is out of array bounds.

ARR30-C

V595

Pointer was used before its check for nullptr. Check lines: N1, N2.

EXP34-C

V596

Object was created but is not used. Check for missing 'throw' keyword.

MSC13-C

V597

Compiler may delete 'memset' function call that is used to clear 'Foo' buffer. Use the RtlSecureZeroMemory() function to erase private data.

MSC06-C

V598

The 'memset/memcpy' function is used to nullify/copy fields of 'Foo' class. Virtual table pointer will be damaged.

EXP62-CPP, OOP57-CPP

V599

The virtual destructor is not present, although the 'Foo' class contains virtual functions.

OOP52-CPP

V600

The 'Foo' pointer is always not equal to NULL. Consider inspecting the condition.

EXP08-C

V601

Suspicious implicit type casting.

INT36-C

V603

Object was created but not used. If you wish to call constructor, use 'this->Foo::Foo(....)'.

MSC13-C

V604

Number of iterations in loop equals size of a pointer. Consider inspecting the expression.

ARR01-C

V605

Unsigned value is compared to the NN number. Consider inspecting the expression.

INT02-C

V606

Ownerless token 'Foo'.

MSC12-C

V609

Possible division or mod by zero.

INT33-C

V610

Undefined behavior. Check the shift operator.

INT34-C

V611

Memory allocation and deallocation methods are incompatible.

MEM51-CPP

V612

Unconditional 'break/continue/return/goto' within a loop.

MSC01-C

V613

Suspicious pointer arithmetic with 'malloc/new'.

EXP08-C

V614

Use of 'Foo' uninitialized variable.

EXP33-C, EXP53-CPP

V615

Suspicious explicit conversion from 'float *' type to 'double *' type.

FLP34-C

V618

Dangerous call of 'Foo' function. The passed line may contain format specification. Example of safe code: printf("%s", str);

FIO30-C

V619

Array is used as pointer to single object.

EXP08-C

V620

Expression of sizeof(T)*N kind is summed up with pointer to T type. Consider inspecting the expression.

EXP08-C

V621

Loop may execute incorrectly or may not execute at all. Consider inspecting the 'for' operator.

MSC21-C

V622

First 'case' operator may be missing. Consider inspecting the 'switch' statement.

DCL41-C

V623

Temporary object is created and then destroyed. Consider inspecting the '?:' operator.

DCL30-C

V628

It is possible that a line was commented out improperly, thus altering the program's operation logic.

EXP19-C

V629

Bit shifting of the 32-bit value with a subsequent expansion to the 64-bit type. Consider inspecting the expression.

INT00-C

V630

The 'malloc' function is used to allocate memory for an array of objects that are classes containing constructors/destructors.

MEM53-CPP

V632

Argument is of the 'T' type. Consider inspecting the NN argument of the 'Foo' function.

EXP37-C

V633

The '!=' operator should probably be used here. Consider inspecting the expression.

EXP45-C

V634

Priority of '+' operation is higher than priority of '<<' operation. Consider using parentheses in the expression.

EXP00-C

V635

Length should be probably multiplied by sizeof(wchar_t). Consider inspecting the expression.

MEM35-C

V636

Expression was implicitly cast from integer type to real type. Consider using an explicit type cast to avoid overflow or loss of a fractional part.

FLP06-C

V639

One of closing ')' parentheses is probably positioned incorrectly. Consider inspecting the expression for function call.

EXP37-C

V640

Code's operational logic does not correspond with its formatting.

EXP19-C

V641

Buffer size is not a multiple of element size.

EXP36-C

V642

Function result is saved inside the 'byte' type variable. Significant bits may be lost. This may break the program's logic.

INT31-C

V643

Suspicious pointer arithmetic. Value of 'char' type is added to a string pointer.

ARR30-C, EXP08-C

V645

Function call may lead to buffer overflow. Bounds should not contain size of a buffer, but a number of characters it can hold.

STR31-C, ARR30-C

V647

Value of 'A' type is assigned to a pointer of 'B' type.

INT36-C

V648

Priority of '&&' operation is higher than priority of '||' operation.

EXP00-C

V649

Two 'if' statements with identical conditional expressions. The first 'if' statement contains function return. This means that the second 'if' statement is senseless.

MSC12-C

V650

Type casting is used 2 times in a row. The '+' operation is executed. Probably meant: (T1)((T2)a + b).

EXP08-C

V658

Value is subtracted from unsigned variable. It can result in an overflow. In such a case, the comparison operation may behave unexpectedly.

INT30-C

V662

Different containers are used to set up initial and final values of iterator. Consider inspecting the loop expression.

CTR53-CPP

V664

Pointer is dereferenced on the initialization list before its check for null inside the body of a constructor function.

EXP34-C

V665

Possible incorrect use of '#pragma warning(default: X)'. The '#pragma warning(push/pop)' should be used instead.

MSC00-C

V666

Value may not correspond with the length of a string passed with YY argument. Consider inspecting the NNth argument of the 'Foo' function.

EXP37-C

V667

The 'throw' operator does not have any arguments and is not located within the 'catch' block.

ERR50-CPP

V668

Possible meaningless check for null, as memory was allocated using 'new' operator. Memory allocation will lead to an exception.

MEM52-CPP

V670

Uninitialized class member is used to initialize another member. Remember that members are initialized in the order of their declarations inside a class.

EXP33-C, EXP53-CPP

V671

The 'swap' function may interchange a variable with itself.

EXP37-C

V673

More than N bits are required to store the value, but the expression evaluates to the T type which can only hold K bits.

INT02-C

V674

Expression contains a suspicious mix of integer and real types.

FLP36-C

V675

Writing into read-only memory.

STR30-C, ENV30-C

V676

Incorrect comparison of BOOL type variable with TRUE.

INT31-C

V677

Custom declaration of standard type. Consider using the declaration from system header files instead.

DCL37-C

V679

The 'X' variable was not initialized. This variable is passed by reference to the 'Foo' function in which its value will be used.

EXP33-C, EXP53-CPP

V681

The language standard does not define order in which 'Foo' functions are called during evaluation of arguments.

EXP10-C

V687

Size of array calculated by sizeof() operator was added to a pointer. It is possible that the number of elements should be calculated by sizeof(A)/sizeof(A[0]).

EXP08-C

V688

The 'foo' local variable has the same name as one of class members. This can result in confusion.

DCL01-C

V689

Destructor of 'Foo' class is not declared as virtual. A smart pointer may not destroy an object correctly.

OOP52-CPP

V692

Inappropriate attempt to append a null character to a string. To determine the length of a string by 'strlen' function correctly, use a string ending with a null terminator in the first place.

STR32-C

V694

The condition (ptr - const_value) is only false if the value of a pointer equals a magic constant.

ARR30-C

V695

Range intersections are possible within conditional expressions.

MSC01-C

V696

The 'continue' operator will terminate 'do { ... } while (FALSE)' loop because the condition is always false.

MSC01-C

V697

Number of elements in the allocated array equals the size of a pointer in bytes.

ARR01-C

V698

Functions of strcmp() kind can return any values, not only -1, 0, or 1.

EXP12-C

V699

It is possible that 'foo = bar == baz ? .... : ....' should be used here instead of 'foo = bar = baz ? .... : ....'. Consider inspecting the expression.

EXP45-C

V701

Possible realloc() leak: when realloc() fails to allocate memory, original pointer is lost. Consider assigning realloc() to a temporary pointer.

WIN30-C, MEM51-CPP

V703

It is suspicious that the 'foo' field in derived class overwrites field in base class.

DCL01-C

V705

It is possible that 'else' block was forgotten or commented out, thus altering the program's operation logics.

EXP19-C

V708

Dangerous construction is used: 'm[x] = m.size()', where 'm' is of 'T' class. This may lead to undefined behavior.

EXP50-CPP

V709

Suspicious comparison found: 'a == b == c'. Remember that 'a == b == c' is not equal to 'a == b && b == c'.

EXP13-C

V711

It is dangerous to create a local variable within a loop with a same name as a variable controlling this loop.

DCL01-C

V712

Compiler may optimize out this loop or make it infinite. Use volatile variable(s) or synchronization primitives to avoid this.

MSC06-C

V713

Pointer was used in the logical expression before its check for nullptr in the same logical expression.

EXP34-C

V714

Variable is not passed into foreach loop by reference, but its value is changed inside of the loop.

MSC13-C

V715

The 'while' operator has empty body. This pattern is suspicious.

EXP15-C

V716

Suspicious type conversion: HRESULT -> BOOL (BOOL -> HRESULT).

INT31-C

V719

The switch statement does not cover all values of the enum.

MSC01-C

V721

The VARIANT_BOOL type is used incorrectly. The true value (VARIANT_TRUE) is defined as -1.

INT31-C

V722

Abnormality within similar comparisons. It is possible that a typo is present inside the expression.

MSC01-C

V723

Function returns a pointer to the internal string buffer of a local object, which will be destroyed.

DCL30-C

V724

Converting integers or pointers to BOOL can lead to a loss of high-order bits. Non-zero value can become 'FALSE'.

INT31-C

V726

Attempt to free memory containing the 'int A[10]' array by using the 'free(A)' function.

MEM34-C

V727

Return value of 'wcslen' function is not multiplied by 'sizeof(wchar_t)'.

STR31-C

V730

Not all members of a class are initialized inside the constructor.

EXP53-CPP

V732

Unary minus operator does not modify a bool type value.

INT31-C

V733

It is possible that macro expansion resulted in incorrect evaluation order.

PRE01-C

V736

The behavior is undefined for arithmetic or comparisons with pointers that do not point to members of the same array.

ARR36-C

V738

Temporary anonymous object is used.

DCL30-C

V739

EOF should not be compared with a value of the 'char' type. Consider using the 'int' type.

INT31-C

V742

Function receives an address of a 'char' type variable instead of pointer to a buffer.

EXP37-C

V743

The memory areas must not overlap. Use 'memmove' function.

EXP37-C

V744

Temporary object is immediately destroyed after being created. Consider naming the object.

MSC13-C

V746

Object slicing. An exception should be caught by reference rather than by value.

ERR61-CPP

V747

Suspicious expression inside parentheses. A function name may be missing.

MSC01-C

V748

Memory for 'getline' function should be allocated only by 'malloc' or 'realloc' functions. Consider inspecting the first parameter of 'getline' function.

MEM51-CPP

V749

Destructor of the object will be invoked a second time after leaving the object's scope.

MEM53-CPP

V751

Parameter is not used inside function's body.

MSC13-C

V752

Creating an object with placement new requires a buffer of large size.

MEM54-CPP

V755

Copying from unsafe data source. Buffer overflow is possible.

STR31-C

V757

It is possible that an incorrect variable is compared with null after type conversion using 'dynamic_cast'.

EXP12-C

V758

Reference was invalidated because of destruction of the temporary object returned by the function.

EXP54-CPP

V759

Violated order of exception handlers. Exception caught by handler for base class.

ERR54-CPP

V763

Parameter is always rewritten in function body before being used.

MSC13-C

V764

Possible incorrect order of arguments passed to function.

EXP37-C

V769

The pointer in the expression equals nullptr. The resulting value is meaningless and should not be used.

EXP08-C

V772

Calling the 'delete' operator for a void pointer will cause undefined behavior.

MSC15-C

V773

Function exited without releasing the pointer/handle. A memory/resource leak is possible.

MEM31-C, MEM51-CPP

V774

Pointer was used after the memory was released.

MEM30-C, MEM50-CPP

V777

Dangerous widening type conversion from an array of derived-class objects to a base-class pointer.

CTR56-CPP

V779

Unreachable code was detected. It is possible that an error is present.

MSC12-C

V780

The object of non-passive (non-PDS) type cannot be used with the function.

EXP62-CPP, OOP57-CPP

V781

Value of a variable is checked after it is used. Possible error in program's logic. Check lines: N1, N2.

API00-C, MEM35-C, CTR50-CPP

V782

It is pointless to compute the distance between the elements of different arrays.

ARR36-C

V783

Possible dereference of invalid iterator 'X'.

CTR51-CPP

V784

The size of the bit mask is less than the size of the first operand. This will cause the loss of the higher bits.

INT31-C

V785

Constant expression in switch statement.

MSC01-C

V786

Assigning the value C to the X variable looks suspicious. The value range of the variable: [A, B].

MSC01-C

V788

Review captured variable in lambda expression.

EXP53-CPP

V789

Iterators for the container, used in the range-based for loop, become invalid upon a function call.

CTR53-CPP

V793

It is suspicious that the result of the statement is a part of the condition. Perhaps, this statement should have been compared with something else.

INT31-C

V796

A 'break' statement is probably missing in a 'switch' statement.

MSC17-C

V797

The function is used as if it returned a bool type. The return value of the function should probably be compared with std::string::npos.

EXP12-C

V798

The size of the dynamic array can be less than the number of elements in the initializer.

ARR02-C

V816

It is more efficient to catch exception by reference rather than by value.

ERR61-CPP

V821

The variable can be constructed in a lower level scope.

DCL19-C

V1001

Variable is assigned but not used by the end of the function.

MSC13-C

V1004

Pointer was used unsafely after its check for nullptr.

EXP34-C, EXP37-C, EXP08-C

V1006

Several shared_ptr objects are initialized by the same pointer. A double memory deallocation will occur.

MEM56-CPP

V1007

Value from the uninitialized optional is used. It may be an error.

EXP53-CPP

V1012

The expression is always false. Overflow check is incorrect.

INT30-C

V1014

Structures with members of real type are compared byte-wise.

FLP37-C

V1015

Suspicious simultaneous use of bitwise and logical operators.

EXP46-C

V1016

The value is out of range of enum values. This causes unspecified or undefined behavior.

INT50-CPP

V1019

Compound assignment expression is used inside condition.

INT31-C

V1023

A pointer without owner is added to the container by the 'emplace_back' method. A memory leak will occur in case of an exception.

ERR56-CPP

V1024

Potential use of invalid data. The stream is checked for EOF before reading from it but is not checked after reading.

FIO40-C

V1026

The variable is incremented in the loop. Undefined behavior will occur in case of signed integer overflow.

INT32-C

V1028

Possible overflow. Consider casting operands, not the result.

INT30-C

V1029

Numeric Truncation Error. Return value of function is written to N-bit variable.

INT31-C

V1030

Variable is used after it is moved.

EXP63-CPP

V1031

Function is not declared. The passing of data to or from this function may be affected.

DCL31-C

V1032

Pointer is cast to a more strictly aligned pointer type.

EXP36-C

V1034

Do not use real-type variables as loop counters.

FLP30-C

V1035

Only values returned from fgetpos() can be used as arguments to fsetpos().

FIO44-C

V1041

Class member is initialized with dangling reference.

EXP54-CPP

V1045

The DllMain function throws an exception. Consider wrapping the throw operator in a try..catch block.

DCL57-CPP

V1046

Unsafe usage of the 'bool' and integer types together in the operation '&='.

INT31-C

V1047

Lifetime of the lambda is greater than lifetime of the local variable captured by reference.

EXP61-CPP

V1050

Uninitialized class member is used when initializing the base class.

EXP33-C, EXP53-CPP

V1053

Calling the 'foo' virtual function in the constructor/destructor may lead to unexpected result at runtime.

OOP50-CPP

V1054

Object slicing. Derived class object was copied to the base class object.

OOP51-CPP

V1057

Pseudo random sequence is the same at every program run. Consider assigning the seed to a value not known at compile-time.

MSC51-CPP

V1058

Nonsensical comparison of two different functions' addresses.

EXP16-C

V1059

Macro name overrides a keyword/reserved name. This may lead to undefined behavior.

DCL51-CPP

V1061

Extending 'std' or 'posix' namespace may result in undefined behavior.

DCL58-CPP

V1066

The 'SysFreeString' function should be called only for objects of the 'BSTR' type.

MEM51-CPP

V1068

Do not define an unnamed namespace in a header file.

DCL59-CPP

V1070

Signed value is converted to an unsigned one with subsequent expansion to a larger type in ternary operator.

INT32-C

V1072

Buffer needs to be securely cleared on all execution paths.

MEM03-C

V2001

Consider using the extended version of the 'foo' function here.

MSC24-C

V2002

Consider using the 'Ptr' version of the 'foo' function here.

MSC24-C

V2003

Explicit conversion from 'float/double' type to signed integer type.

FLP34-C

V2004

Explicit conversion from 'float/double' type to unsigned integer type.

FLP34-C

V2014

Don't use terminating functions in library code.

ERR50-CPP

V2015

An identifier declared in an inner scope should not hide an identifier in an outer scope.

DCL01-C

V5002

OWASP. An empty exception handler. Silent suppression of exceptions can hide the presence of bugs in source code during testing.

ERR56-CPP

V5003

OWASP. The object was created but it is not being used. The 'throw' keyword could be missing.

MSC13-C

V5004

OWASP. Consider inspecting the expression. Bit shifting of the 32-bit value with a subsequent expansion to the 64-bit type.

INT00-C

V5005

OWASP. A value is being subtracted from the unsigned variable. This can result in an overflow. In such a case, the comparison operation can potentially behave unexpectedly.

INT30-C

V5006

OWASP. More than N bits are required to store the value, but the expression evaluates to the T type which can only hold K bits.

INT02-C

V5010

OWASP. The variable is incremented in the loop. Undefined behavior will occur in case of signed integer overflow.

INT32-C

V5011

OWASP. Possible overflow. Consider casting operands, not the result.

INT30-C

Java диагностики

Error Code

Error Description

Mapping

V5301

OWASP. An exception handling block does not contain any code.

ERR00-J

V5304

OWASP. Unsafe double-checked locking.

LCK10-J

V6002

The switch statement does not cover all values of the enum.

MSC57-J

V6003

The use of 'if (A) {...} else if (A) {...}' pattern was detected. There is a probability of logical error presence.

MSC57-J

V6005

The 'x' variable is assigned to itself.

MSC56-J

V6007

Expression is always true/false.

MSC57-J

V6008

Potential null dereference.

EXP01-J

V6010

The return value of function 'Foo' is required to be utilized.

EXP00-J

V6011

The expression contains a suspicious mix of integer and real types.

NUM13-J

V6013

Comparison of arrays, strings, collections by reference. Possibly an equality comparison was intended.

EXP03-J

V6018

Constant expression in switch statement.

MSC57-J

V6020

Division or mod division by zero.

NUM02-J

V6021

The value is assigned to the 'x' variable but is not used.

MSC56-J

V6022

Parameter is not used inside method's body.

MSC56-J

V6026

This value is already assigned to the 'b' variable.

MSC56-J

V6031

The variable 'X' is being used for this loop and for the outer loop.

MSC57-J

V6034

Shift by N bits is inconsistent with the size of type.

NUM14-J

V6037

An unconditional 'break/continue/return/goto' within a loop.

MSC57-J

V6038

Comparison with 'double.NaN' is meaningless. Use 'double.isNaN()' method instead.

NUM07-J

V6039

There are two 'if' statements with identical conditional expressions. The first 'if' statement contains method return. This means that the second 'if' statement is senseless.

MSC56-J

V6041

Suspicious assignment inside the conditional expression of 'if/while/do...while' statement.

EXP51-J

V6044

Postfix increment/decrement is senseless because this variable is overwritten.

EXP05-J

V6049

Classes that define 'equals' method must also define 'hashCode' method.

MET09-J

V6050

Class initialization cycle is present.

DCL00-J

V6051

Use of jump statements in 'finally' block can lead to the loss of unhandled exceptions.

ERR04-J

V6052

Calling an overridden method in parent-class constructor may lead to use of uninitialized data.

MET05-J

V6053

Collection is modified while iteration is in progress. ConcurrentModificationException may occur.

MSC06-J

V6054

Classes should not be compared by their name.

OBJ09-J

V6055

Expression inside assert statement can change object's state.

EXP06-J

V6057

Consider inspecting this expression. The expression is excessive or contains a misprint.

MSC57-J

V6061

The used constant value is represented by an octal form.

DCL50-J

V6063

Odd semicolon ';' after 'if/for/while' operator.

MSC51-J

V6064

Suspicious invocation of Thread.run().

THI00-J

V6066

Passing objects of incompatible types to the method of collection.

EXP04-J

V6068

Suspicious use of BigDecimal class.

NUM10-J

V6070

Unsafe synchronization on an object.

LCK01-J

V6073

It is not recommended to return null or throw exceptions from 'toString' / 'clone' methods.

EXP01-J

V6074

Non-atomic modification of volatile variable.

VNA02-J

V6075

The signature of method 'X' does not conform to serialization requirements.

SER01-J

V6077

A suspicious label is present inside a switch(). It is possible that these are misprints and 'default:' label should be used instead.

MSC57-J

V6082

Unsafe double-checked locking.

LCK10-J

V6089

It's possible that the line was commented out improperly, thus altering the program's operation logics.

EXP52-J

V6093

Automatic unboxing of a variable may cause NullPointerException.

EXP01-J

V6095

Thread.sleep() inside synchronized block/method may cause decreased performance.

LCK09-J

V6097

Lowercase 'L' at the end of a long literal can be mistaken for '1'.

DCL50-J

V6101

compareTo()-like methods can return not only the values -1, 0 and 1, but any values.

EXP00-J

Этот сайт использует куки и другие технологии, чтобы предоставить вам более персонализированный опыт. Продолжая просмотр страниц нашего веб-сайта, вы принимаете условия использования этих файлов. Если вы не хотите, чтобы ваши данные обрабатывались, пожалуйста, покиньте данный сайт. Подробнее →
Принять