summaryrefslogtreecommitdiff
path: root/driver/xf86-video-nv/compat/modes/xf86cvt.c
diff options
context:
space:
mode:
Diffstat (limited to 'driver/xf86-video-nv/compat/modes/xf86cvt.c')
-rw-r--r--driver/xf86-video-nv/compat/modes/xf86cvt.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/driver/xf86-video-nv/compat/modes/xf86cvt.c b/driver/xf86-video-nv/compat/modes/xf86cvt.c
index 69ccc4259..e9c74aa62 100644
--- a/driver/xf86-video-nv/compat/modes/xf86cvt.c
+++ b/driver/xf86-video-nv/compat/modes/xf86cvt.c
@@ -20,11 +20,6 @@
* OTHER DEALINGS IN THE SOFTWARE.
*/
-/**
- * @file This is a copy of xf86cvt.c from the X Server, for compatibility with
- * old servers (pre-1.2).
- */
-
/*
* The reason for having this function in a file of its own is
* so that ../utils/cvt/cvt can link to it, and that xf86CVTMode
@@ -72,7 +67,7 @@ _X_EXPORT DisplayModePtr
xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
Bool Interlaced)
{
- DisplayModeRec *Mode = xnfalloc(sizeof(DisplayModeRec));
+ DisplayModeRec *Mode = xnfcalloc(1, sizeof(DisplayModeRec));
/* 1) top/bottom margin size (% of height) - default: 1.8 */
#define CVT_MARGIN_PERCENTAGE 1.8
@@ -95,8 +90,6 @@ xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
int VDisplayRnd, VMargin, VSync;
float Interlace; /* Please rename this */
- memset(Mode, 0, sizeof(DisplayModeRec));
-
/* CVT default is 60.0Hz */
if (!VRefresh)
VRefresh = 60.0;