[llvm] r293330 - Fix ASAN failure in cxa_demangle
Kostya Serebryany via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 27 12:59:50 PST 2017
Do we want to fuzz llvm/trunk/lib/Demangle/ItaniumDemangle.cpp in addition
to libcxxabi/trunk/src/cxa_demangle.cpp?
Are we going to have both long term, or just one?
On Fri, Jan 27, 2017 at 12:32 PM, Mehdi Amini via llvm-commits <
llvm-commits at lists.llvm.org> wrote:
> Author: mehdi_amini
> Date: Fri Jan 27 14:32:16 2017
> New Revision: 293330
>
> URL: http://llvm.org/viewvc/llvm-project?rev=293330&view=rev
> Log:
> Fix ASAN failure in cxa_demangle
>
> Found with ASAN + libFuzzer by Kostya Serebryany <kcc at google.com>
>
> Modified:
> llvm/trunk/lib/Demangle/ItaniumDemangle.cpp
>
> Modified: llvm/trunk/lib/Demangle/ItaniumDemangle.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/
> Demangle/ItaniumDemangle.cpp?rev=293330&r1=293329&r2=293330&view=diff
> ============================================================
> ==================
> --- llvm/trunk/lib/Demangle/ItaniumDemangle.cpp (original)
> +++ llvm/trunk/lib/Demangle/ItaniumDemangle.cpp Fri Jan 27 14:32:16 2017
> @@ -1402,7 +1402,8 @@ static const char *parse_function_type(c
> int ref_qual = 0;
> while (true) {
> if (t == last) {
> - db.names.pop_back();
> + if (!db.names.empty())
> + db.names.pop_back();
> return first;
> }
> if (*t == 'E') {
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170127/70a388a3/attachment.html>
More information about the llvm-commits
mailing list