GNU bug report logs - #74444
[PATCH] parted: fix do_version declaration

Previous Next

Package: parted;

Reported by: Rudi Heitbaum <rudi <at> heitbaum.com>

Date: Wed, 20 Nov 2024 12:55:01 UTC

Severity: normal

Tags: patch

Done: "Brian C. Lane" <bcl <at> redhat.com>

To reply to this bug, email your comments to 74444 AT debbugs.gnu.org.
There is no need to reopen the bug first.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-parted <at> gnu.org:
bug#74444; Package parted. (Wed, 20 Nov 2024 12:55:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Rudi Heitbaum <rudi <at> heitbaum.com>:
New bug report received and forwarded. Copy sent to bug-parted <at> gnu.org. (Wed, 20 Nov 2024 12:55:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Rudi Heitbaum <rudi <at> heitbaum.com>
To: bug-parted <at> gnu.org
Cc: rudi <at> heitbaum.com
Subject: [PATCH] parted: fix do_version declaration
Date: Wed, 20 Nov 2024 12:22:22 +0000
With gcc 15-20241117 compile fails with the below error, update the
do_version declaration to match the header in command.h

../../parted/parted.c: In function '_init_commands':
../../parted/parted.c:2469:9: error: passing argument 2 of 'command_create' from incompatible pointer type [-Wincompatible-pointer-types]
 2469 |         do_version,
      |         ^~~~~~~~~~
      |         |
      |         int (*)(void)
In file included from ../../parted/parted.c:28:
../../parted/command.h:35:39: note: expected 'int (*)(PedDevice **, PedDisk **)' {aka 'int (*)(struct _PedDevice **, struct _PedDisk **)'} but argument is of type 'int (*)(void)'
   35 |                                 int (*method) (PedDevice** dev, PedDisk** diskp),
      |                                 ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Rudi Heitbaum <rudi <at> heitbaum.com>
---
 parted/parted.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/parted/parted.c b/parted/parted.c
index 3abb52f..fc2aeba 100644
--- a/parted/parted.c
+++ b/parted/parted.c
@@ -2172,7 +2172,7 @@ do_unit (PedDevice** dev, PedDisk** diskp)
 }
 
 static int
-do_version ()
+do_version (PedDevice** dev, PedDisk** diskp)
 {
     printf ("\n%s\n%s",
             prog_name,
-- 
2.43.0





Reply sent to "Brian C. Lane" <bcl <at> redhat.com>:
You have taken responsibility. (Wed, 20 Nov 2024 17:07:02 GMT) Full text and rfc822 format available.

Notification sent to Rudi Heitbaum <rudi <at> heitbaum.com>:
bug acknowledged by developer. (Wed, 20 Nov 2024 17:07:02 GMT) Full text and rfc822 format available.

Message #10 received at 74444-done <at> debbugs.gnu.org (full text, mbox):

From: "Brian C. Lane" <bcl <at> redhat.com>
To: Rudi Heitbaum <rudi <at> heitbaum.com>
Cc: 74444-done <at> debbugs.gnu.org
Subject: Re: bug#74444: [PATCH] parted: fix do_version declaration
Date: Wed, 20 Nov 2024 09:06:34 -0800
On Wed, Nov 20, 2024 at 12:22:22PM +0000, Rudi Heitbaum wrote:

>  static int
> -do_version ()
> +do_version (PedDevice** dev, PedDisk** diskp)
>  {
>      printf ("\n%s\n%s",
>              prog_name,

Thanks!

Brian

-- 
Brian C. Lane (PST8PDT) - weldr.io - lorax - parted - pykickstart





This bug report was last modified 9 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.