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

Unified Diff: tools/traceline/traceline/scripts/crit_sec.py

Issue 8678023: Fix python scripts in src/tools/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes Created 9 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/traceline/traceline/scripts/alloc.py ('k') | tools/traceline/traceline/scripts/filter_short.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/traceline/traceline/scripts/crit_sec.py
diff --git a/tools/traceline/traceline/scripts/crit_sec.py b/tools/traceline/traceline/scripts/crit_sec.py
index f43f50d3bdae8cee2e47e0ac8018b13954e9294e..ee710bd2032429faea4a095312963674e7eb9b1a 100755
--- a/tools/traceline/traceline/scripts/crit_sec.py
+++ b/tools/traceline/traceline/scripts/crit_sec.py
@@ -1,13 +1,13 @@
-# Copyright (c) 2009 The Chromium Authors. All rights reserved.
+#!/usr/bin/env python
+# Copyright (c) 2011 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import sys
import os
-execfile(os.path.join(
- os.path.dirname(os.path.join(os.path.curdir, __file__)),
- 'syscalls.py'))
+from syscalls import syscalls
+
def parseEvents(z):
crits = { }
@@ -48,4 +48,10 @@ def parseEvents(z):
#raise repr(tid_stack)
pass
-execfile(sys.argv[1])
+
+def main():
+ execfile(sys.argv[1])
+
+
+if __name__ == '__main__':
+ main()
« no previous file with comments | « tools/traceline/traceline/scripts/alloc.py ('k') | tools/traceline/traceline/scripts/filter_short.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698