diff options
-rw-r--r-- | src/scripts/genXplatLttng.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/scripts/genXplatLttng.py b/src/scripts/genXplatLttng.py index fae0e120da..9959895f5a 100644 --- a/src/scripts/genXplatLttng.py +++ b/src/scripts/genXplatLttng.py @@ -284,6 +284,10 @@ TRACEPOINT_EVENT_INSTANCE(\\ def generateMethodBody(template, providerName, eventName): #emit code to init variables convert unicode to ansi string result = [] + + if template is None: + return "\n do_tracepoint(%s, %s);\n" % (providerName, eventName) + fnSig = template.signature for paramName in fnSig.paramlist: @@ -454,9 +458,8 @@ def generateLttngTpProvider(providerName, eventNodes, allTemplates): lTTngImpl.append(" if (!EventXplatEnabled%s())\n" % (eventName,)) lTTngImpl.append(" return ERROR_SUCCESS;\n") - if template: - result = generateMethodBody(template, providerName, eventName) - lTTngImpl.append(result) + result = generateMethodBody(template, providerName, eventName) + lTTngImpl.append(result) lTTngImpl.append("\n return ERROR_SUCCESS;\n}\n\n") |