Skip to content
This repository was archived by the owner on Oct 27, 2021. It is now read-only.

Commit

Permalink
Merge pull request #93 from joernio/michael/upgrade4
Browse files Browse the repository at this point in the history
use latest odb/cpg
  • Loading branch information
mpollmeier authored Jul 20, 2021
2 parents 9b2068e + 9ffcf68 commit 1b61734
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ThisBuild/organization := "io.joern"
ThisBuild/scalaVersion := "2.13.5"
// don't upgrade to 2.13.6 until https://github.com/com-lihaoyi/Ammonite/issues/1182 is resolved

val cpgVersion = "1.3.212"
val cpgVersion = "1.3.239"

enablePlugins(JavaAppPackaging)
enablePlugins(GitVersioning)
Expand Down
2 changes: 1 addition & 1 deletion project/build.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sbt.version=1.5.4
sbt.version=1.5.5
2 changes: 1 addition & 1 deletion src/main/scala/io/joern/scanners/c/CopyLoops.scala
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ object CopyLoops extends QueryBundle {
|""".stripMargin,
score = 2,
withStrRep({ cpg =>
cpg.assignment.target.isArrayAccess
cpg.assignment.target.arrayAccess
.map { access =>
(access.array, access.subscripts.code.toSet)
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/io/joern/scanners/c/FileOpRace.scala
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ object FileOpRace extends QueryBundle {
|""".stripMargin,
score = 3.0,
withStrRep({ cpg =>
val operations: Map[String, Seq[Integer]] = Map(
val operations: Map[String, Seq[Int]] = Map(
"access" -> Seq(1),
"chdir" -> Seq(1),
"chmod" -> Seq(1),
Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/io/joern/scanners/c/NullTermination.scala
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ object NullTermination extends QueryBundle {
case (method, dst, size) =>
dst.reachableBy(allocations).codeExact(size.code).nonEmpty &&
method.assignments
.where(_.target.isArrayAccess.code(s"${dst.code}.*\\[.*"))
.where(_.target.arrayAccess.code(s"${dst.code}.*\\[.*"))
.source
.isLiteral
.code(".*0.*")
Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/io/joern/scanners/c/UseAfterFree.scala
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ object UseAfterFree extends QueryBundle {
.where(_.argument(1).isIdentifier)
.flatMap(f => {
val freedIdentifierCode = f.argument(1).code
val postDom = f.postDominatedBy.toSet
val postDom = f.postDominatedBy.toSetImmutable

val assignedPostDom = postDom.isIdentifier
.where(_.inAssignment)
Expand Down

0 comments on commit 1b61734

Please sign in to comment.