~ubuntu-branches/ubuntu/feisty/rdesktop/feisty-updates

« back to all changes in this revision

Viewing changes to rdesktop.c

  • Committer: Bazaar Package Importer
  • Author(s): Jamie Strandboge
  • Date: 2008-09-17 16:00:53 UTC
  • mfrom: (7.1.2 feisty-updates)
  • Revision ID: james.westby@ubuntu.com-20080917160053-nb70u2hvw152aamp
Tags: 1.5.0-1ubuntu1.1
* SECURITY UPDATE: fix integer overflow in iso.c that could cause denial
  of service or possibly remote code execution
* SECURITY UPDATE: fix buffer overflow in rdp.c that could cause allow
  remote code execution via redirect requests
* SECURITY UPDATE: fix integer signedness error that may allow remote
  code execution via heap-based overflow
* References
  CVE-2008-1801
  CVE-2008-1802
  CVE-2008-1803
  LP: #228193

Show diffs side-by-side

added added

removed removed

Lines of Context:
1052
1052
 
1053
1053
/* malloc; exit if out of memory */
1054
1054
void *
1055
 
xmalloc(int size)
 
1055
xmalloc(size_t size)
1056
1056
{
1057
1057
        void *mem = malloc(size);
1058
1058
        if (mem == NULL)
1078
1078
 
1079
1079
/* realloc; exit if out of memory */
1080
1080
void *
1081
 
xrealloc(void *oldmem, int size)
 
1081
xrealloc(void *oldmem, size_t size)
1082
1082
{
1083
1083
        void *mem;
1084
1084
 
1085
 
        if (size < 1)
 
1085
        if (size == 0)
1086
1086
                size = 1;
1087
1087
        mem = realloc(oldmem, size);
1088
1088
        if (mem == NULL)
1089
1089
        {
1090
 
                error("xrealloc %d\n", size);
 
1090
                error("xrealloc %ld\n", size);
1091
1091
                exit(1);
1092
1092
        }
1093
1093
        return mem;