Changeset d35d2ba


Ignore:
Timestamp:
Feb 9, 2010, 9:49:36 PM (11 years ago)
Author:
Anders Kaseorg <andersk@mit.edu>
Branches:
master, release-1.6, release-1.7, release-1.8, release-1.9
Children:
dacb555
Parents:
3f18ad5
git-author:
Anders Kaseorg <andersk@mit.edu> (02/08/10 22:40:45)
git-committer:
Anders Kaseorg <andersk@mit.edu> (02/09/10 21:49:36)
Message:
zcrypt: Don’t leak the body after decrypting a message.

This fixes a leak noticed by nelhage.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Reviewed-by: Nelson Elhage <nelhage@mit.edu>
File:
1 edited

Legend:

Unmodified
Added
Removed
  • message.c

    re9c6fc8 rd35d2ba  
    846846    out=owl_malloc(strlen(owl_message_get_body(m))*16+20);
    847847    ret=owl_zcrypt_decrypt(out, owl_message_get_body(m), owl_message_get_class(m), owl_message_get_instance(m));
    848     if (ret==0) {
     848    if (ret == 0)
    849849      owl_message_set_body(m, out);
    850     } else {
    851       owl_free(out);
    852     }
     850    owl_free(out);
    853851  }
    854852#endif 
Note: See TracChangeset for help on using the changeset viewer.