about summary refs log tree commit diff
path: root/.custom-format.py
diff options
context:
space:
mode:
authorvan Hauser <vh@thc.org>2020-05-12 11:04:18 +0200
committerGitHub <noreply@github.com>2020-05-12 11:04:18 +0200
commit1317433a51a7f7336c82c80a592835ddda9ef60f (patch)
treee623506f1d0a8771c3fc266eed0a75b626a88724 /.custom-format.py
parentbdd2a412c476cbd5aea0fff67ef096305815953b (diff)
parenta578d719e1f556db07ca3c7e2fe38b7668c204d8 (diff)
downloadafl++-1317433a51a7f7336c82c80a592835ddda9ef60f.tar.gz
Merge pull request #359 from AFLplusplus/dev
push to master
Diffstat (limited to '.custom-format.py')
-rwxr-xr-x.custom-format.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/.custom-format.py b/.custom-format.py
index 164815b1..6f1b0bfa 100755
--- a/.custom-format.py
+++ b/.custom-format.py
@@ -70,8 +70,8 @@ def custom_format(filename):
     out = ""
     
     for line in src.split("\n"):
-        if line.startswith("#"):
-            if line.startswith("#define"):
+        if line.lstrip().startswith("#"):
+            if line[line.find("#")+1:].lstrip().startswith("define"):
                 in_define = True
         
         if "/*" in line and not line.strip().startswith("/*") and line.endswith("*/") and len(line) < (COLUMN_LIMIT-2):