gpgme memory leak? What's wrong?

Christian Biere christianbiere at gmx.de
Mon Mar 20 21:21:32 CET 2006


Marcus Brinkmann wrote:
> At Mon, 27 Feb 2006 19:41:45 +0300,
> "Vladimir S. Petukhov" <vladimir at sycore.org> wrote:
> The code you quoted is not valid C code.

Neither is yours. Obviously, the code was compiled with an ISO C99
compiler which defines "true". Real men use "for (;;)" of course. The
address operator before a function name is redundant. Identation style
has nothing to do with validity and is not defined by any revision of
the C standard. That said the GNU style is rather unpopular. What is
missing, though, is a main function, #include lines, variable and
function declarations.

> After fixing the syntactical errors, I produced the below version,
> which runs fine without any memory leaks.

No, the real issue have not been fixed at all.

> If you give me a self-standing, compiling source code file, I can try
> it out as well.  You can also try running valgrind on your program.

*flame thrower off*

Okay, you have a point here.

-- 
Christian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 188 bytes
Desc: not available
Url : /pipermail/attachments/20060320/b78316be/attachment.pgp


More information about the Gnupg-devel mailing list