Commit 02568ec5 authored by Keith Packard's avatar Keith Packard
Browse files

kdrive: vesa get mode using uninitialized value

parent 8f634a65
......@@ -19,7 +19,7 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
/* $XFree86: xc/programs/Xserver/hw/kdrive/vesa/vbe.c,v 1.5 2000/09/27 20:46:37 keithp Exp $ */
/* $XFree86: xc/programs/Xserver/hw/kdrive/vesa/vbe.c,v 1.6 2000/10/20 00:19:50 keithp Exp $ */
#include "vesa.h"
......@@ -128,7 +128,7 @@ VbeGetModes (Vm86InfoPtr vi, VesaModePtr modes, int nmode)
if (code < 0)
return code;
memset (modes, '\0', n * sizeof (VesaModeRec));
memset (modes, '\0', nmode * sizeof (VesaModeRec));
p = MAKE_POINTER_1(vib.VideoModePtr);
for (n = 0; n < nmode; n++)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment