diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-05-23 20:16:00 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-05-23 20:16:00 +0200 |
commit | 94988a2b4e6bd85ee8216c65cc8cd73d14cf1ad1 (patch) | |
tree | b10414cf2c2d85136861bae6df7ab1d0295c439a /tools/jprof/strset.cpp | |
parent | 542da56e2c4f992afb50c4222dcf757c3a3e6a5c (diff) | |
download | UXP-94988a2b4e6bd85ee8216c65cc8cd73d14cf1ad1.tar UXP-94988a2b4e6bd85ee8216c65cc8cd73d14cf1ad1.tar.gz UXP-94988a2b4e6bd85ee8216c65cc8cd73d14cf1ad1.tar.lz UXP-94988a2b4e6bd85ee8216c65cc8cd73d14cf1ad1.tar.xz UXP-94988a2b4e6bd85ee8216c65cc8cd73d14cf1ad1.zip |
Remove the jprof profiler.
This resolves #377.
Diffstat (limited to 'tools/jprof/strset.cpp')
-rw-r--r-- | tools/jprof/strset.cpp | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/tools/jprof/strset.cpp b/tools/jprof/strset.cpp deleted file mode 100644 index 623ad3f90..000000000 --- a/tools/jprof/strset.cpp +++ /dev/null @@ -1,40 +0,0 @@ -/* This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ - -#include "strset.h" -#include <malloc.h> -#include <string.h> - -StrSet::StrSet() -{ - strings = 0; - numstrings = 0; -} - -void StrSet::add(const char* s) -{ - if (strings) { - strings = (char**) realloc(strings, (numstrings + 1) * sizeof(char*)); - } else { - strings = (char**) malloc(sizeof(char*)); - } - strings[numstrings] = strdup(s); - numstrings++; -} - -int StrSet::contains(const char* s) -{ - char** sp = strings; - int i = numstrings; - - while (--i >= 0) { - char *ss = *sp++; - if (ss[0] == s[0]) { - if (strcmp(ss, s) == 0) { - return 1; - } - } - } - return 0; -} |