Skip to content

Commit

Permalink
fix infinite recursion when there are no proto files to compile
Browse files Browse the repository at this point in the history
  • Loading branch information
ninjudd committed Jul 18, 2012
1 parent 3ce5fc5 commit 60ea5d9
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/leiningen/protobuf.clj
Expand Up @@ -147,8 +147,8 @@
(defn compile
"Compile protocol buffer files located in proto dir."
([project]
(apply compile project (proto-files (proto-path project))))
([project & files]
(compile project (proto-files (proto-path project))))
([project files]
(build-protoc project)
(when (and (= "protobuf" (:name project)))
(compile-google-protobuf project))
Expand All @@ -163,4 +163,6 @@
(defn protobuf
"Task for compiling protobuf libraries."
[project & args]
(apply compile project args))
(if (seq args)
(compile project args)
(compile project)))

0 comments on commit 60ea5d9

Please sign in to comment.