Messages in this thread | | | Date | Mon, 3 Apr 2006 05:15:04 -0700 | From | Mitchell Blank Jr <> | Subject | Re: [PATCH] Silence a const vs non-const warning |
| |
Jan-Benedict Glaw wrote: > This patch silences a const vs. non-const warning issued by very > recent GCC versions: > > $ vax-linux-uclibc-gcc -v 2>&1 | grep version [...] > void *memcpy(void *dest, const void *src, size_t count) > { > char *tmp = dest; > - char *s = src; > + const char *s = src;
Actually the compiler version has nothing to do with it -- I'm pretty sure even gcc 2.X would warn on that. The actual reason that most people don't see that is that an arch w/o __HAVE_ARCH_MEMCPY is pretty rare.
Still, no reason for the reference C version of that function to emit a warning, so it's worth fixing.
-Mitch - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |