Fix the talloc leaks I introduced by not spotting these returns.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Mar 31 05:19:34 CEST 2011 on sn-devel-104
if (cd->pull(cd->cd_pull,
inbuf, inbytesleft, &bufp1, &bufsize) == -1
- && errno != E2BIG) return -1;
+ && errno != E2BIG) {
+ talloc_free(cvtbuf);
+ return -1;
+ }
bufsize = SMB_ICONV_BUFSIZE - bufsize;
if (cd->push(cd->cd_push,
&bufp2, &bufsize,
- outbuf, outbytesleft) == -1) return -1;
+ outbuf, outbytesleft) == -1) {
+ talloc_free(cvtbuf);
+ return -1;
+ }
}
talloc_free(cvtbuf);
}