X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=src%2Fbindings%2Fpython%2Fbt2%2Fbt2%2Fnative_bt_trace_class.i.h;h=68ea78c4a9113c69892d1f38a24de2ef88ee31df;hp=329fda6555c04df0eae3e3b01226036bf37010c3;hb=0235b0db7de5bcacdb3650c92461f2ce5eb2143d;hpb=64961f8b6306c567fd2683d19a1bdee1331a8d5b diff --git a/src/bindings/python/bt2/bt2/native_bt_trace_class.i.h b/src/bindings/python/bt2/bt2/native_bt_trace_class.i.h index 329fda65..68ea78c4 100644 --- a/src/bindings/python/bt2/bt2/native_bt_trace_class.i.h +++ b/src/bindings/python/bt2/bt2/native_bt_trace_class.i.h @@ -1,25 +1,7 @@ /* - * The MIT License (MIT) + * SPDX-License-Identifier: MIT * * Copyright (c) 2016 Philippe Proulx - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - * THE SOFTWARE. */ static void @@ -32,13 +14,12 @@ trace_class_destroyed_listener(const bt_trace_class *trace_class, void *py_calla SWIGTYPE_p_bt_trace_class, 0); if (!py_trace_class_ptr) { BT_LOGF_STR("Failed to create a SWIG pointer object."); - abort(); + bt_common_abort(); } py_res = PyObject_CallFunction(py_callable, "(O)", py_trace_class_ptr); if (!py_res) { - logw_exception(BT_LOG_OUTPUT_LEVEL); - PyErr_Clear(); + logw_exception_clear(BT_LOG_OUTPUT_LEVEL); goto end; }