linux/drivers/staging/rt2870
Anders Kaseorg 2fefd5f668 Staging: rt2870: Don't call sprintf() with overlapping input and output.
The use of sprintf() to append to a buffer, as in
  sprintf(buf, "%sEntry: %d\n", buf, i)
is not valid according to C99 ("If copying takes place between objects
that overlap, the behavior is undefined.").  It breaks at least in
userspace under gcc -D_FORTIFY_SOURCE.  Replace this construct with
  sprintf(buf + strlen(buf), "Entry: %d\n", i)

This patch was automatically generated using
  perl -0pe 's/(sprintf\s*\(\s*([^,]*))(\s*,\s*")%s((?:[^"\\]|\\.)*"\s*,)\s*\2\s*,/$1 + strlen($2)$3$4/g'
  perl -0pe 's/(snprintf\s*\(\s*([^,]*))(\s*,[^,]*?)(\s*,\s*")%s((?:[^"\\]|\\.)*"\s*,)\s*\2\s*,/$1 + strlen($2)$3 - strlen($2)$4$5/g'

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-06-19 11:00:36 -07:00
..
common Staging: rt2870: Don't call sprintf() with overlapping input and output. 2009-06-19 11:00:36 -07:00
sta Staging: rt2870: Don't call sprintf() with overlapping input and output. 2009-06-19 11:00:36 -07:00
2870_main_dev.c Staging: rt2870: Removal of kernel_thread() API 2009-04-03 14:53:31 -07:00
aironet.h
ap.h
chlist.h
dfs.h
Kconfig
leap.h
link_list.h
Makefile
md4.h
md5.h
mlme.h
netif_block.h
oid.h
rt28xx.h
rt2870.h Staging: rt2870: new device id 2009-05-08 19:39:27 -07:00
rt_ate.c staging: __FUNCTION__ is gcc-specific, use __func__ 2009-01-07 15:48:54 -08:00
rt_ate.h
rt_config.h
rt_linux.c Staging: rt2860: fix printk format warnings 2009-04-03 14:53:31 -07:00
rt_linux.h Staging: rt2870: Removal of kernel_thread() API 2009-04-03 14:53:31 -07:00
rt_main_dev.c Staging: rt2870: convert to netdev_ops 2009-04-17 11:06:25 -07:00
rt_profile.c staging: __FUNCTION__ is gcc-specific, use __func__ 2009-01-07 15:48:54 -08:00
rtmp.h
rtmp_ckipmic.h
rtmp_def.h staging: __FUNCTION__ is gcc-specific, use __func__ 2009-01-07 15:48:54 -08:00
rtmp_type.h
spectrum.h
spectrum_def.h
sta_ioctl.c Staging: rt2870: Don't call sprintf() with overlapping input and output. 2009-06-19 11:00:36 -07:00
sta_ioctl.c.patch
tmp60 staging: __FUNCTION__ is gcc-specific, use __func__ 2009-01-07 15:48:54 -08:00
tmp61 staging: __FUNCTION__ is gcc-specific, use __func__ 2009-01-07 15:48:54 -08:00
TODO staging: document that the wifi staging drivers a bit better 2009-04-03 14:54:27 -07:00
wpa.h