Date: Fri, 28 Nov 2008 14:53:18 +0000 (UTC) From: Ed Schouten <ed@FreeBSD.org> To: cvs-src-old@freebsd.org Subject: cvs commit: src/sys/kern uipc_mqueue.c Message-ID: <200811281453.mASErNgH043033@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
ed 2008-11-28 14:53:18 UTC FreeBSD src repository Modified files: sys/kern uipc_mqueue.c Log: SVN rev 185385 on 2008-11-28 14:53:18Z by ed Fix matching of message queues by name. The mqfs_search() routine uses strncmp() to match message queue objects by name. This is because it can be called from environments where the file name is not null terminated (the VFS for example). Unfortunately it doesn't compare the lengths of the message queue names, which means if a system has "Queue12345", the name "Queue" will also match. I noticed this when a student of mine handed in an exercise using message queues with names "Queue2" and "Queue". Reviewed by: rink Revision Changes Path 1.39 +2 -1 src/sys/kern/uipc_mqueue.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200811281453.mASErNgH043033>