gecko-dev/netwerk/streamconv
Henri Sivonen 3a8d018880 Bug 1487398 - Remove useless use of SetCapacity(). r=froydnj,nwgh
Remove various calls to SetCapacity() that fall into various misuse categories:

 1) Mistakenly believing that the caller should advice the string about zero
    terminator.
 2) Cases where a single append does the right computation on its own.
 3) Calling SetCapacity() with a constant when the string is self-allocated
    and could be an nsAuto[C]StringN and the string doesn't get passed on
    in a way that could benefit from a heap-allocated buffer.
 4) Calling SetCapacity() before assigning a shared buffer to the string.
 5) Calling SetCapacity() before calling a function that will either calls
    SetLength() anyway or calls Adopt().

MozReview-Commit-ID: IKjfl5gLmcD

Differential Revision: https://phabricator.services.mozilla.com/D4672

--HG--
extra : moz-landing-system : lando
2018-09-25 15:36:31 +00:00
..
converters Bug 1487398 - Remove useless use of SetCapacity(). r=froydnj,nwgh 2018-09-25 15:36:31 +00:00
moz.build
mozITXTToHTMLConv.idl
nsIDirIndex.idl Bug 1489365 - Part 1: Remove the XPCOM component registration for nsDirIndex; r=valentin 2018-09-07 14:25:56 -04:00
nsIDirIndexListener.idl Bug 1489365 - Part 3: Remove the unused @mozilla.org/dirIndexListener;1 contract ID; r=valentin 2018-09-07 14:25:59 -04:00
nsIStreamConverter.idl
nsIStreamConverterService.idl
nsITXTToHTMLConv.idl
nsStreamConverterService.cpp Bug 1457813 - Part 2: Replace non-asserting NS_PRECONDITIONs with MOZ_ASSERTs. r=froydnj 2018-04-28 12:50:58 -07:00
nsStreamConverterService.h Bug 1457411 - Update netwerk module to make use of newer methods introduced with c++11 and c++14. r=valentin 2018-04-30 19:46:04 +03:00