diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2024-01-21 16:05:43 -0800 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2024-01-21 16:05:43 -0800 |
commit | 692b6a728e08ff4e936728b904d7b13bc4d301ed (patch) | |
tree | 9a2373c04a39b3d7be7e14cc94e1d9ea88bca987 /msg.c | |
parent | 8b22282c564763bb3fb6baf5aae7b341dfbb33db (diff) |
Convert allocation calls to XtMallocArray or XtReallocArray where appropriate
Raises minimum libXt requirement to 1.3.0 for these calls
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Diffstat (limited to 'msg.c')
-rw-r--r-- | msg.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -302,8 +302,7 @@ static void SetScrnNewMsg( } } else { msg->num_scrns++; - msg->scrn = (Scrn *) XtRealloc((char *)msg->scrn, - (unsigned) sizeof(Scrn)*msg->num_scrns); + msg->scrn = XtReallocArray(msg->scrn, msg->num_scrns, sizeof(Scrn)); msg->scrn[msg->num_scrns - 1] = scrn; if (msg->source == NULL) msg->source = CreateFileSource(scrn->viewwidget, MsgFileName(msg), |