aboutsummaryrefslogtreecommitdiffstats
path: root/com32/include/sys
diff options
context:
space:
mode:
authorErwan <erwan@seanodes.com>2008-03-08 22:51:54 +0100
committerH. Peter Anvin <hpa@zytor.com>2008-03-20 16:33:34 -0700
commit23b6a5adf17d534fe152c0ea9f5617caee20a7c3 (patch)
tree1abcc220d00423da6067504ba2a2db4dad49e258 /com32/include/sys
parentb890569a44cf9c5afce6e5ca648dc9b589e964f9 (diff)
downloadsyslinux-23b6a5adf17d534fe152c0ea9f5617caee20a7c3.tar.gz
syslinux-23b6a5adf17d534fe152c0ea9f5617caee20a7c3.tar.xz
syslinux-23b6a5adf17d534fe152c0ea9f5617caee20a7c3.zip
PCI detection code doesn't corrupt memory anymore (2nd try)
From : Erwan Velu <erwan.velu@free.fr> This patch fixes the pci detection stuff demo'd in pcitest.c32 - Fix a wrong type in malloc - Incorrect use of strdup - Replacing strncpy by strnlcpy (thx hpa) This two fixes makes pcitest.c32 working far better, no more crash when running it twice. I'd like to thank Sebastian Herbszt for its reports and tests. This patch was made for 3.62-pre16 but applies fine on 3.63-pre1. Signed-off-by:Erwan Velu <erwan.velu@free.fr> -------------------------------------------------------------------------------- Les opinions et prises de position emises par le signataire du present message lui sont propres et ne sauraient engager la responsabilite de la societe SEANODES. Ce message ainsi que les eventuelles pieces jointes constituent une correspondance privee et confidentielle a l'attention exclusive du destinataire designe ci-dessus. Si vous n'etes pas le destinataire du present message ou une personne susceptible de pouvoir le lui delivrer, il vous est signifie que toute divulgation, distribution ou copie de cette transmission est strictement interdite. Si vous avez recu ce message par erreur, nous vous remercions d'en informer l'expediteur par telephone ou de lui retourner le present message, puis d'effacer immediatement ce message de votre systeme. The views and opinions expressed by the author of this message are personal. SEANODES shall assume no liability, express or implied for such message. This e-mail and any attachments is a confidential correspondence intended only for use of the individual or entity named above. If you are not the intended recipient or the agent responsible for delivering the message to the intended recipient, you are hereby notified that any disclosure, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify the sender by phone or by replying this message, and then delete this message from your system.
Diffstat (limited to 'com32/include/sys')
-rw-r--r--com32/include/sys/pci.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/com32/include/sys/pci.h b/com32/include/sys/pci.h
index 3f9b0d97..a49475b6 100644
--- a/com32/include/sys/pci.h
+++ b/com32/include/sys/pci.h
@@ -11,9 +11,9 @@ typedef uint32_t pciaddr_t;
/* a structure for extended pci information */
struct pci_dev_info {
- char *vendor_name;
- char *product_name;
- char *linux_kernel_module;
+ char vendor_name[255];
+ char product_name[255];
+ char linux_kernel_module[64];
};
/* a struct to represent a pci device */