src: fix debugging for multiple categories

Fix parsing of e.g. `NODE_DEBUG_NATIVE=worker,messaging`.

PR-URL: https://github.com/nodejs/node/pull/21422
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This commit is contained in:
Anna Henningsen authored and Michaël Zasso committed 2018-06-22 11:01:25 +02:00
1 parent e7776c63da
commit 2377aec000
1 file changed
+1 -1
+1 -1
View File
@@ -537,7 +537,7 @@ void Environment::set_debug_categories(const std::string& cats, bool enabled) {
if (comma_pos == std::string::npos)
break;
// Use everything after the `,` as the list for the next iteration.
debug_categories = debug_categories.substr(comma_pos);
debug_categories = debug_categories.substr(comma_pos + 1);
}
}