earnol

Results issues of earnol

tpws service fails to start with desync mode. error description in debug mode: ``` /jffs/dpi/tpws --bind-addr 192.168.0.1 --port 999 --disorder --tlsrec=sni --split-pos=2 --pidfile /var/run/tpws.pid --debug=2 Prepare bind 0 : addr=192.168.0.1...

The misc-redundant-expression produces a warning with latest trunk build where it should not. In the example below two different defines are being compared. Those defines different, yet happens to have...

clang-tidy
false-positive

The conditional-uninitialized diagnostics checker issue warnings even in cases when the initialization is clearly performed. Here is the example: ``` int a(int p1) { int cv = 1; int ibn;...

clang:diagnostics

The warning for line like: ``` if (a >= b =b

clang:diagnostics

I have encountered compiler crash with the following stack trace signifying error in the ASTImporter (reproducible with https://github.com/llvm/llvm-project/commit/9269aaecffb7050dddbbe5d17ddd9f3ca2e577f0). The reason of the error is improper import of some AST subtrees:...

clang:frontend
crash

This issue appeared after pull request: https://github.com/llvm/llvm-project/pull/136855 I have noticed excessive reporting with constant NULL pointer for the new C++ compatibly warnings implemented in https://github.com/llvm/llvm-project/commit/15321d2c9e686b382262339fa17c5445b1b2609f. Please see the following code:...

question
c
clang:diagnostics
confirmed
false-negative

The newly added warning via https://github.com/llvm/llvm-project/pull/150028/ is causes warning in unexpected situation. Please see the following [godbolt example](https://godbolt.org/#g:!((g:!((g:!((h:codeEditor,i:(filename:'1',fontScale:14,fontUsePx:'0',j:1,lang:___c,selection:(endColumn:12,endLineNumber:20,positionColumn:12,positionLineNumber:20,selectionStartColumn:12,selectionStartLineNumber:20,startColumn:12,startLineNumber:20),source:'%23include+%3Cstdlib.h%3E%0A%23include+%3Cstdio.h%3E%0A%0Atypedef+unsigned+long+size_t%3B%0A%0Avoid+*realloc(void+*ptr,+size_t+size)+__attribute__((alloc_size(2)))%3B%0Avoid+*malloc(size_t+size)+__attribute__((alloc_size(1)))%3B%0A%0A%0Aint+f2_realloc_1()+%7B%0A++int+*p+%3D+(int+*)malloc(12)%3B%0A++int+*q+%3D+(int+*)realloc(p,+0)%3B+//+expected-warning+%7B%7Ballocation+of+insufficient+size+!'0!'+for+type+!'int!'+with+size+!'1!'%7D%7D%0A++printf(%22Pointer+is:+%25p%22,+q)%3B%0A++return+p+!!%3D+q%3B%0A%7D%0A%0Aint+main()%0A%7B%0A++f2_realloc_1()%3B%0A++return+0%3B%0A%7D%0A%0A//+-Xclang+-analyzer-checker%3Dcore++-Xclang+-analyzer-checker%3Dalpha.deadcode.UnreachableCode++-Xclang++-analyzer-checker%3Dalpha.core.CastSize+++-Xclang+-analyzer-checker%3Dunix++-Xclang+-analyzer-checker%3Ddebug.ExprInspection+++-Xclang+-analyzer-checker%3Doptin.taint.TaintPropagation+++-Xclang+-analyzer-checker%3Doptin.taint.TaintedAlloc%0A'),l:'5',n:'0',o:'C+source+%231',t:'0')),header:(),k:34.71001224185383,l:'4',n:'0',o:'',s:0,t:'0'),(g:!((h:compiler,i:(compiler:cclang_trunk,filters:(b:'0',binary:'1',binaryObject:'1',commentOnly:'0',debugCalls:'1',demangle:'0',directives:'0',execute:'0',intel:'0',libraryCode:'0',trim:'1',verboseDemangling:'0'),flagsViewOpen:'1',fontScale:14,fontUsePx:'0',j:1,lang:___c,libs:!(),options:'-Xclang+-analyzer-checker%3Dcore++-Xclang+-analyzer-checker%3Dalpha.deadcode.UnreachableCode++-Xclang++-analyzer-checker%3Dalpha.core.CastSize+++-Xclang+-analyzer-checker%3Dunix++-Xclang+-analyzer-checker%3Ddebug.ExprInspection+++-Xclang+-analyzer-checker%3Doptin.taint.TaintPropagation+++-Xclang+-analyzer-checker%3Doptin.taint.TaintedAlloc',overrides:!(),selection:(endColumn:1,endLineNumber:1,positionColumn:1,positionLineNumber:1,selectionStartColumn:1,selectionStartLineNumber:1,startColumn:1,startLineNumber:1),source:1),l:'5',n:'0',o:'+x86-64+clang+(trunk)+(Editor+%231)',t:'0')),header:(),k:35.652365515388325,l:'4',n:'0',o:'',s:0,t:'0'),(g:!((h:output,i:(compilerName:'x86-64+clang+20.1.0',editorid:1,fontScale:14,fontUsePx:'0',j:1,wrap:'1'),l:'5',n:'0',o:'Output+of+x86-64+clang+(trunk)+(Compiler+%231)',t:'0')),k:29.637622242757846,l:'4',n:'0',o:'',s:0,t:'0')),l:'2',n:'0',o:'',t:'0')),version:4). In this example in line 12 the warning is generated, however the...

clang:diagnostics

Attribute alloc_size aimed to help compiler to determine size parameters is limited to only two use cases: ``` void* calloc( size_t num, size_t size ) __attribute__((alloc_size(1, 2))); void* malloc( size_t...

clang:frontend

Since the commit https://github.com/llvm/llvm-project/commit/b24769855d97697de08e2296a548c033f193caf4 and associated pull request https://github.com/llvm/llvm-project/pull/157364 the following code: ``` #include int afunc(unsigned long * v) { return v != NULL; } unsigned long mdarr[5][6]; unsigned long...

invalid
clang:diagnostics

The core.StackAddressEscape produce invalid disgnostics (false positive) in the following case: ``` #include class LocalClass; class VEI { public: VEI():pLocal(nullptr) {} LocalClass *pLocal; }; class LocalClass { public: LocalClass(VEI *v):p(v)...

clang:static analyzer
false-positive