Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(299)

Side by Side Diff: Source/core/xml/XSLTUnicodeSort.cpp

Issue 1161323007: Use nullptr instead of 0 in xml and xmlhttprequest. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Updated as per review comment & modified in other files which assigned "0" to ptr. Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/xml/XSLTProcessorLibxslt.cpp ('k') | Source/core/xmlhttprequest/XMLHttpRequest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2009 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 // Based on default implementation from libxslt 1.1.22 and xsltICUSort.c 44 // Based on default implementation from libxslt 1.1.22 and xsltICUSort.c
45 // example. 45 // example.
46 void xsltUnicodeSortFunction(xsltTransformContextPtr ctxt, xmlNodePtr *sorts, in t nbsorts) 46 void xsltUnicodeSortFunction(xsltTransformContextPtr ctxt, xmlNodePtr *sorts, in t nbsorts)
47 { 47 {
48 #ifdef XSLT_REFACTORED 48 #ifdef XSLT_REFACTORED
49 xsltStyleItemSortPtr comp; 49 xsltStyleItemSortPtr comp;
50 #else 50 #else
51 xsltStylePreCompPtr comp; 51 xsltStylePreCompPtr comp;
52 #endif 52 #endif
53 xmlXPathObjectPtr* resultsTab[XSLT_MAX_SORT]; 53 xmlXPathObjectPtr* resultsTab[XSLT_MAX_SORT];
54 xmlXPathObjectPtr* results = 0; 54 xmlXPathObjectPtr* results = nullptr;
55 xmlNodeSetPtr list = 0; 55 xmlNodeSetPtr list = nullptr;
56 int depth; 56 int depth;
57 xmlNodePtr node; 57 xmlNodePtr node;
58 int tempstype[XSLT_MAX_SORT], temporder[XSLT_MAX_SORT]; 58 int tempstype[XSLT_MAX_SORT], temporder[XSLT_MAX_SORT];
59 59
60 if (!ctxt || !sorts || nbsorts <= 0 || nbsorts >= XSLT_MAX_SORT) 60 if (!ctxt || !sorts || nbsorts <= 0 || nbsorts >= XSLT_MAX_SORT)
61 return; 61 return;
62 if (!sorts[0]) 62 if (!sorts[0])
63 return; 63 return;
64 comp = static_cast<xsltStylePreComp*>(sorts[0]->psvi); 64 comp = static_cast<xsltStylePreComp*>(sorts[0]->psvi);
65 if (!comp) 65 if (!comp)
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
266 } 266 }
267 if (resultsTab[j]) { 267 if (resultsTab[j]) {
268 for (int i = 0; i < len; ++i) 268 for (int i = 0; i < len; ++i)
269 xmlXPathFreeObject(resultsTab[j][i]); 269 xmlXPathFreeObject(resultsTab[j][i]);
270 xmlFree(resultsTab[j]); 270 xmlFree(resultsTab[j]);
271 } 271 }
272 } 272 }
273 } 273 }
274 274
275 } // namespace blink 275 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/xml/XSLTProcessorLibxslt.cpp ('k') | Source/core/xmlhttprequest/XMLHttpRequest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698