Skip to content

Commit

Permalink
Normalize all text files to LF
Browse files Browse the repository at this point in the history
Use `* text=auto eol=lf`
  • Loading branch information
dave-bartolomeo committed Sep 23, 2018
1 parent 26abf5d commit 1f36f55
Show file tree
Hide file tree
Showing 25 changed files with 178 additions and 177 deletions.
4 changes: 2 additions & 2 deletions .editorconfig
@@ -1,2 +1,2 @@
[*]
end_of_line = lf
[*]
end_of_line = lf
73 changes: 37 additions & 36 deletions .gitattributes
@@ -1,40 +1,41 @@
# The following file types will be normalized to LF line endings in the Git
# database, and will keep those LF line endings in the working tree even on
# Windows. Any other files will have whatever line endings they had when they
# were committed. If you add new entries below, you should renormalize the
# affected files by running the following from the root of this repo (requires
# Git 2.16 or greater):
# Text files will be normalized to LF line endings in the Git database, and will keep those LF line
# endings in the working tree even on Windows. If you make changes below, you should renormalize the
# affected files by running the following from the root of this repo (requires Git 2.16 or greater):
#
# git add --renormalize .
# git status [just to show what files were renormalized]
# git commit -m "Normalize line endings"
#
# Also, please update .editorconfig to handle any new entries as well.
*.ql eol=lf
*.qll eol=lf
*.qlref eol=lf
*.dbscheme eol=lf
*.qhelp eol=lf
*.html eol=lf
*.htm eol=lf
*.xhtml eol=lf
*.xhtm eol=lf
*.js eol=lf
*.mjs eol=lf
*.ts eol=lf
*.json eol=lf
*.yml eol=lf
*.yaml eol=lf
*.c eol=lf
*.cpp eol=lf
*.h eol=lf
*.hpp eol=lf
*.md eol=lf
*.stats eol=lf
*.xml eol=lf
*.sh eol=lf
*.pl eol=lf
*.java eol=lf
*.cs eol=lf
*.py eol=lf
*.lua eol=lf

# Anything Git auto-detects as text gets normalized and checked out as LF
* text=auto eol=lf

# Explicitly set a bunch of known extensions to text, in case auto detection gets confused.
*.ql text
*.qll text
*.qlref text
*.dbscheme text
*.qhelp text
*.html text
*.htm text
*.xhtml text
*.xhtm text
*.js text
*.mjs text
*.ts text
*.json text
*.yml text
*.yaml text
*.c text
*.cpp text
*.h text
*.hpp text
*.md text
*.stats text
*.xml text
*.sh text
*.pl text
*.java text
*.cs text
*.py text
*.lua text
*.expected text
26 changes: 13 additions & 13 deletions cpp/config/suites/security/cwe-120
@@ -1,13 +1,13 @@
# CWE-120: Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')
+ semmlecode-cpp-queries/Security/CWE/CWE-120/UnboundedWrite.ql: /CWE/CWE-120
@name Unbounded write (CWE-120)
+ semmlecode-cpp-queries/Security/CWE/CWE-120/BadlyBoundedWrite.ql: /CWE/CWE-120
@name Badly bounded write (CWE-120)
+ semmlecode-cpp-queries/Security/CWE/CWE-120/OverrunWrite.ql: /CWE/CWE-120
@name Potentially overrunning write (CWE-120)
+ semmlecode-cpp-queries/Security/CWE/CWE-120/OverrunWriteFloat.ql: /CWE/CWE-120
@name Potentially overrunning write with float to string conversion (CWE-120)
+ semmlecode-cpp-queries/Best Practices/Likely Errors/OffsetUseBeforeRangeCheck.ql: /CWE/CWE-120
@name Array offset used before range check (CWE-120)
+ semmlecode-cpp-queries/Likely Bugs/Memory Management/UnsafeUseOfStrcat.ql: /CWE/CWE-120
@name Potentially unsafe use of strcat (CWE-120)
# CWE-120: Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')
+ semmlecode-cpp-queries/Security/CWE/CWE-120/UnboundedWrite.ql: /CWE/CWE-120
@name Unbounded write (CWE-120)
+ semmlecode-cpp-queries/Security/CWE/CWE-120/BadlyBoundedWrite.ql: /CWE/CWE-120
@name Badly bounded write (CWE-120)
+ semmlecode-cpp-queries/Security/CWE/CWE-120/OverrunWrite.ql: /CWE/CWE-120
@name Potentially overrunning write (CWE-120)
+ semmlecode-cpp-queries/Security/CWE/CWE-120/OverrunWriteFloat.ql: /CWE/CWE-120
@name Potentially overrunning write with float to string conversion (CWE-120)
+ semmlecode-cpp-queries/Best Practices/Likely Errors/OffsetUseBeforeRangeCheck.ql: /CWE/CWE-120
@name Array offset used before range check (CWE-120)
+ semmlecode-cpp-queries/Likely Bugs/Memory Management/UnsafeUseOfStrcat.ql: /CWE/CWE-120
@name Potentially unsafe use of strcat (CWE-120)
6 changes: 3 additions & 3 deletions cpp/config/suites/security/cwe-121
@@ -1,3 +1,3 @@
# CWE-121: Stack-based Buffer Overflow
+ semmlecode-cpp-queries/Security/CWE/CWE-121/UnterminatedVarargsCall.ql: /CWE/CWE-121
@name Unterminated variadic call (CWE-121)
# CWE-121: Stack-based Buffer Overflow
+ semmlecode-cpp-queries/Security/CWE/CWE-121/UnterminatedVarargsCall.ql: /CWE/CWE-121
@name Unterminated variadic call (CWE-121)
14 changes: 7 additions & 7 deletions cpp/config/suites/security/cwe-131
@@ -1,7 +1,7 @@
# CWE-131: Incorrect Calculation of Buffer Size
+ semmlecode-cpp-queries/Security/CWE/CWE-131/NoSpaceForZeroTerminator.ql: /CWE/CWE-131
@name No space for zero terminator (CWE-131)
+ semmlecode-cpp-queries/Critical/SizeCheck.ql: /CWE/CWE-131
@name Not enough memory allocated for pointer type (CWE-131)
+ semmlecode-cpp-queries/Critical/SizeCheck2.ql: /CWE/CWE-131
@name Not enough memory allocated for array of pointer type (CWE-131)
# CWE-131: Incorrect Calculation of Buffer Size
+ semmlecode-cpp-queries/Security/CWE/CWE-131/NoSpaceForZeroTerminator.ql: /CWE/CWE-131
@name No space for zero terminator (CWE-131)
+ semmlecode-cpp-queries/Critical/SizeCheck.ql: /CWE/CWE-131
@name Not enough memory allocated for pointer type (CWE-131)
+ semmlecode-cpp-queries/Critical/SizeCheck2.ql: /CWE/CWE-131
@name Not enough memory allocated for array of pointer type (CWE-131)
26 changes: 13 additions & 13 deletions cpp/config/suites/security/cwe-134
@@ -1,13 +1,13 @@
# CWE-134: Uncontrolled Format String
+ semmlecode-cpp-queries/Likely Bugs/Format/NonConstantFormat.ql: /CWE/CWE-134
@name Non-constant format string (CWE-134)
# This one runs out of memory. See ODASA-608.
#+ semmlecode-cpp-queries/PointsTo/TaintedFormatStrings.ql: /CWE/CWE-134
+ semmlecode-cpp-queries/Likely Bugs/Format/WrongNumberOfFormatArguments.ql: /CWE/CWE-134
@name Wrong number of arguments to formatting function (CWE-134)
+ semmlecode-cpp-queries/Likely Bugs/Format/WrongTypeFormatArguments.ql: /CWE/CWE-134
@name Wrong type of arguments to formatting function (CWE-134)
+ semmlecode-cpp-queries/Security/CWE/CWE-134/UncontrolledFormatString.ql: /CWE/CWE-134
@name Uncontrolled format string (CWE-134)
+ semmlecode-cpp-queries/Security/CWE/CWE-134/UncontrolledFormatStringThroughGlobalVar.ql: /CWE/CWE-134
@name Uncontrolled format string (through global variable) (CWE-134)
# CWE-134: Uncontrolled Format String
+ semmlecode-cpp-queries/Likely Bugs/Format/NonConstantFormat.ql: /CWE/CWE-134
@name Non-constant format string (CWE-134)
# This one runs out of memory. See ODASA-608.
#+ semmlecode-cpp-queries/PointsTo/TaintedFormatStrings.ql: /CWE/CWE-134
+ semmlecode-cpp-queries/Likely Bugs/Format/WrongNumberOfFormatArguments.ql: /CWE/CWE-134
@name Wrong number of arguments to formatting function (CWE-134)
+ semmlecode-cpp-queries/Likely Bugs/Format/WrongTypeFormatArguments.ql: /CWE/CWE-134
@name Wrong type of arguments to formatting function (CWE-134)
+ semmlecode-cpp-queries/Security/CWE/CWE-134/UncontrolledFormatString.ql: /CWE/CWE-134
@name Uncontrolled format string (CWE-134)
+ semmlecode-cpp-queries/Security/CWE/CWE-134/UncontrolledFormatStringThroughGlobalVar.ql: /CWE/CWE-134
@name Uncontrolled format string (through global variable) (CWE-134)
24 changes: 12 additions & 12 deletions cpp/ql/test/.project
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>semmlecode-cpp-tests</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
</buildSpec>
<natures>
<nature>com.semmle.plugin.qdt.core.qlnature</nature>
</natures>
</projectDescription>
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>semmlecode-cpp-tests</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
</buildSpec>
<natures>
<nature>com.semmle.plugin.qdt.core.qlnature</nature>
</natures>
</projectDescription>
2 changes: 1 addition & 1 deletion cpp/ql/test/library-tests/exprs_cast/options
@@ -1 +1 @@
semmle-extractor-options: --edg --target --edg win64
semmle-extractor-options: --edg --target --edg win64
8 changes: 4 additions & 4 deletions cpp/ql/test/library-tests/typename/typename.expected
@@ -1,4 +1,4 @@
| file://:0:0:0:0 | T |
| file://:0:0:0:0 | int |
| file://:0:0:0:0 | myClass |
| file://:0:0:0:0 | short |
| file://:0:0:0:0 | T |
| file://:0:0:0:0 | int |
| file://:0:0:0:0 | myClass |
| file://:0:0:0:0 | short |
2 changes: 1 addition & 1 deletion cpp/ql/test/library-tests/types/__wchar_t/options
@@ -1 +1 @@
semmle-extractor-options: --microsoft
semmle-extractor-options: --microsoft
2 changes: 1 addition & 1 deletion cpp/ql/test/library-tests/types/integral_types_ms/options
@@ -1 +1 @@
semmle-extractor-options: --microsoft --edg --target --edg win64
semmle-extractor-options: --microsoft --edg --target --edg win64
2 changes: 1 addition & 1 deletion cpp/ql/test/library-tests/types/wchar_t_typedef/options
@@ -1 +1 @@
semmle-extractor-options: --microsoft --edg --target --edg win32
semmle-extractor-options: --microsoft --edg --target --edg win32
2 changes: 1 addition & 1 deletion cpp/ql/test/query-tests/AlertSuppression/.gitattributes
@@ -1 +1 @@
tstWindows.c eol=crlf
tstWindows.c eol=crlf
@@ -1 +1 @@
// g
// g
2 changes: 1 addition & 1 deletion cpp/ql/test/query-tests/Critical/NewFree/options
@@ -1 +1 @@
semmle-extractor-options: --microsoft
semmle-extractor-options: --microsoft
24 changes: 12 additions & 12 deletions csharp/ql/test/.project
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>semmlecode-csharp-tests</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
</buildSpec>
<natures>
<nature>com.semmle.plugin.qdt.core.qlnature</nature>
</natures>
</projectDescription>
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>semmlecode-csharp-tests</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
</buildSpec>
<natures>
<nature>com.semmle.plugin.qdt.core.qlnature</nature>
</natures>
</projectDescription>
40 changes: 20 additions & 20 deletions csharp/ql/test/library-tests/assemblies/Assembly1.cs_
@@ -1,20 +1,20 @@
using System;
namespace Assembly2
{
public delegate int del2(int x);
public class Class2 : Attribute
{
}
public class Class3 : Attribute
{
public class Class4
{
}
public class Class5<T>
{
}
}
}
using System;

namespace Assembly2
{
public delegate int del2(int x);

public class Class2 : Attribute
{
}

public class Class3 : Attribute
{
public class Class4
{
}
public class Class5<T>
{
}
}
}
46 changes: 23 additions & 23 deletions csharp/ql/test/library-tests/assemblies/Assembly2.cs_
@@ -1,23 +1,23 @@
using System;
using Assembly2;
namespace Assembly1
{
[Class3()]
public delegate Class2 del1(Class3 c3);
[Class3()]
public class Class1
{
[Class2()]
static public Class2 a;
static public Class2 b() { return new Class2(); }
[Class3()]
static public Class3.Class4 c(Class3 x) { return new Class3.Class4(); }
[Class2()]
static public int d() { return 1; }
static public del2 e() { return f; }
static public int f(int x) { return x; }
static public Class3.Class5<Class2> g(Class3.Class5<Class2> x) { return x; }
}
}
using System;
using Assembly2;

namespace Assembly1
{
[Class3()]
public delegate Class2 del1(Class3 c3);

[Class3()]
public class Class1
{
[Class2()]
static public Class2 a;
static public Class2 b() { return new Class2(); }
[Class3()]
static public Class3.Class4 c(Class3 x) { return new Class3.Class4(); }
[Class2()]
static public int d() { return 1; }
static public del2 e() { return f; }
static public int f(int x) { return x; }
static public Class3.Class5<Class2> g(Class3.Class5<Class2> x) { return x; }
}
}
2 changes: 1 addition & 1 deletion csharp/ql/test/library-tests/generics/Generics20.expected
@@ -1 +1 @@
| 1 |
| 1 |
6 changes: 3 additions & 3 deletions csharp/ql/test/library-tests/tokens/Tokens1.expected
@@ -1,3 +1,3 @@
| tokens.cs:5:15:5:17 | I1 |
| tokens.cs:10:12:10:14 | S1 |
| tokens.cs:14:11:14:13 | C1 |
| tokens.cs:5:15:5:17 | I1 |
| tokens.cs:10:12:10:14 | S1 |
| tokens.cs:14:11:14:13 | C1 |
@@ -1,11 +1,11 @@
| ReadOnlyContainer.cs:9:16:9:17 | v1 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:13:13:13:14 | v2 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:30:16:30:17 | v3 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:55:13:55:14 | v4 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:76:13:76:14 | v5 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:82:13:82:14 | v6 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:88:13:88:14 | v7 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:91:13:91:14 | v8 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:96:13:96:14 | v9 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:99:13:99:15 | v10 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:9:16:9:17 | v1 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:13:13:13:14 | v2 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:30:16:30:17 | v3 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:55:13:55:14 | v4 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:76:13:76:14 | v5 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:82:13:82:14 | v6 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:88:13:88:14 | v7 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:91:13:91:14 | v8 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:96:13:96:14 | v9 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:99:13:99:15 | v10 | The contents of this container are never initialized. |
| ReadOnlyContainer.cs:121:13:121:15 | v11 | The contents of this container are never initialized. |
14 changes: 7 additions & 7 deletions java/ql/src/.settings/org.eclipse.jdt.core.prefs
@@ -1,7 +1,7 @@
#Tue Nov 04 11:42:37 GMT 2008
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
org.eclipse.jdt.core.compiler.compliance=1.5
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.5
#Tue Nov 04 11:42:37 GMT 2008
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
org.eclipse.jdt.core.compiler.compliance=1.5
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.5
2 changes: 1 addition & 1 deletion java/ql/test/library-tests/comments/.gitattributes
@@ -1 +1 @@
TestWindows.java eol=crlf
TestWindows.java eol=crlf
2 changes: 1 addition & 1 deletion java/ql/test/query-tests/AlertSuppression/.gitattributes
@@ -1 +1 @@
TestWindows.java eol=crlf
TestWindows.java eol=crlf
4 changes: 2 additions & 2 deletions javascript/ql/test/library-tests/Lines/.gitattributes
@@ -1,2 +1,2 @@
# This file intentionally contains a mix of different line endings
tst1.js -text
# This file intentionally contains a mix of different line endings
tst1.js -text

0 comments on commit 1f36f55

Please sign in to comment.