Re: why this statement will cause analysis error?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/21/2010 11:41 AM, Lu Fan wrote:

> I use a tool to check my code, and it reports a error on a statement:
> like:
> 
> typedef a{
> int m;
> char sz_a[11];
> char n;
> }t_a;
> 
> typedef b{
> int i;
> char sz_b[11];
> char j;
> }t_b;
> 
> t_a* in;
> t_b out;
> 
> //......
> 
> memcpy(in->sz_a, out.sz_b,sizeof(in->sz_a));
> 
> the memcpy will cause analysis error? The tool reports Overrun.

Hard to say.  I think you'd better contact the authors of the tool.

Andrew.


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux