diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2011-11-19 10:33:15 -0800 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2011-12-09 17:37:09 -0800 |
commit | e77dd2e4bc8227ebdab70b4233cb33ed690fa264 (patch) | |
tree | c40965b2ffd7dc02afac66aca8ce05b6086d8446 /src/sm_manager.c | |
parent | 46f3ef4460aa2c1c2cba22897694a1cea572d506 (diff) |
Remove a bunch of unnecessary casts with malloc & free calls
With modern compilers and headers, they cause more problems than they
solve and just hide real issues.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Mark Kettenis <kettenis@openbsd.org>
Reviewed-by: James Cloos <cloos@jhcloos.com>
Diffstat (limited to 'src/sm_manager.c')
-rw-r--r-- | src/sm_manager.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sm_manager.c b/src/sm_manager.c index 9e0d187..d28c0c5 100644 --- a/src/sm_manager.c +++ b/src/sm_manager.c @@ -68,7 +68,7 @@ _SmsProtocolSetupProc (IceConn iceConn, * Allocate new SmsConn. */ - if ((smsConn = (SmsConn) malloc (sizeof (struct _SmsConn))) == NULL) + if ((smsConn = malloc (sizeof (struct _SmsConn))) == NULL) { const char *str = "Memory allocation failed"; @@ -335,5 +335,5 @@ SmsCleanUp(SmsConn smsConn) if (smsConn->client_id) free (smsConn->client_id); - free ((char *) smsConn); + free (smsConn); } |