WebKit Bugzilla
Attachment 342925 Details for
Bug 186758
: Correctly close the variable argument list
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-186758-20180618132026.patch (text/plain), 1.77 KB, created by
Tomas Popela
on 2018-06-18 04:20:28 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Tomas Popela
Created:
2018-06-18 04:20:28 PDT
Size:
1.77 KB
patch
obsolete
>Subversion Revision: 232922 >diff --git a/Source/WTF/ChangeLog b/Source/WTF/ChangeLog >index daf38a3bd6e048cfc8a2c1169ff50cc9f80f0e76..07b299fec9162a26409b6d5cb593d12f0541c90e 100644 >--- a/Source/WTF/ChangeLog >+++ b/Source/WTF/ChangeLog >@@ -1,3 +1,15 @@ >+2018-06-18 Tomas Popela <tpopela@redhat.com> >+ >+ Correctly close the variable argument list >+ https://bugs.webkit.org/show_bug.cgi?id=186758 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ The argcCopy is not ended when we early return. >+ >+ * wtf/text/WTFString.cpp: >+ (WTF::createWithFormatAndArguments): >+ > 2018-06-12 Darin Adler <darin@apple.com> > > [Cocoa] Make some RetainPtr refinements to get more ready for ARC >diff --git a/Source/WTF/wtf/text/WTFString.cpp b/Source/WTF/wtf/text/WTFString.cpp >index b24c79f74d2527177f019e487e2d3b70960a3f15..0b9131ae796430c0978889615c1a489d64077504 100644 >--- a/Source/WTF/wtf/text/WTFString.cpp >+++ b/Source/WTF/wtf/text/WTFString.cpp >@@ -463,6 +463,7 @@ WTF_ATTRIBUTE_PRINTF(1, 0) static String createWithFormatAndArguments(const char > auto cfFormat = adoptCF(CFStringCreateWithCString(kCFAllocatorDefault, format, kCFStringEncodingUTF8)); > auto result = adoptCF(CFStringCreateWithFormatAndArguments(kCFAllocatorDefault, nullptr, cfFormat.get(), args)); > va_end(args); >+ va_end(argsCopy); > return result.get(); > } > #endif >@@ -476,10 +477,14 @@ WTF_ATTRIBUTE_PRINTF(1, 0) static String createWithFormatAndArguments(const char > #endif > va_end(args); > >- if (result == 0) >+ if (result == 0) { >+ va_end(argsCopy); > return emptyString(); >- if (result < 0) >+ } >+ if (result < 0) { >+ va_end(argsCopy); > return String(); >+ } > > Vector<char, 256> buffer; > unsigned len = result;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 186758
:
342925
|
342984
|
345657
|
345695