Re: unused variable

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Gaetano Mendola <mendola(at)bigfoot(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: unused variable
Date: 2004-07-20 22:46:55
Message-ID: 200407202246.i6KMktb13619@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


OK, it turns out myXID is only used by Assert tests, and most developers
compile with Asserts. I have fixed this by defining the variable only
when asserts are enabled.

Patch attached and applied.

---------------------------------------------------------------------------

Gaetano Mendola wrote:
[ PGP not available, raw data follows ]
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi all,
>
> I'm compiling the last postgres CVS version and I get:
>
> vacuum.c: In function `repair_frag':
> vacuum.c:1528: warning: unused variable `myXID'
>
>
>
> Regards
> Gaetano Mendola
>
>
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.2.4 (MingW32)
> Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
>
> iD8DBQFA+bCj7UpzwH2SGd4RAtyKAJsH6V22SijBN3VD/HJ/sWoLO8Ta7wCcD1wt
> U2VsEehBuK64q4/kjsHA4g4=
> =TsL8
> -----END PGP SIGNATURE-----
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> message can get through to the mailing list cleanly
>
[ End of raw data]

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

Attachment Content-Type Size
unknown_filename text/plain 666 bytes

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2004-07-20 23:00:28 Re: Patch for pg_dump: Multiple -t options and new -T option
Previous Message Joshua D. Drake 2004-07-20 22:32:50 Re: check point segments leakage ?