From: Jim Meyering Date: Mon, 22 Jun 2009 22:45:27 +0200 Subject: [Cluster-devel] [PATCH gfs2-utils] don't use "void*" in arithmetic In-Reply-To: <20090622203552.GA30072@redhat.com> (David Teigland's message of "Mon, 22 Jun 2009 15:35:53 -0500") References: <871vpcxb3z.fsf@meyering.net> <20090622203552.GA30072@redhat.com> Message-ID: <87skhsvvyw.fsf@meyering.net> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit David Teigland wrote: > On Mon, Jun 22, 2009 at 10:33:04PM +0200, Jim Meyering wrote: >> Building gfs2-utils, I saw these warnings: >> >> main.c:21: warning: pointer of type ???void *??? used in arithmetic >> main.c:38: warning: pointer of type ???void *??? used in arithmetic >> main.c:145: warning: pointer of type ???void *??? used in arithmetic >> main.c:33: warning: pointer of type ???void *??? used in arithmetic >> main.c:50: warning: pointer of type ???void *??? used in arithmetic >> >> Here are patches that add no casts (and yes, that's a feature ;-): > > We've fixed all these in the STABLE3 branch... I thought Fabio had some scheme > in mind for syncing all that work to these new trees. Both to avoid doing the > same work over again, and so we do the same thing in both. i.e. in STABLE3 I > fixed this with write(fd, (char *)buf + off, count); Thanks for the heads-up. Avoiding casts is nice, but not a big deal here. The const-adding parts of the patch are worth keeping, though.