summaryrefslogtreecommitdiffstats
path: root/src/deps_log.h
diff options
context:
space:
mode:
authorNico Weber <nicolasweber@gmx.de>2013-04-30 15:40:56 (GMT)
committerNico Weber <nicolasweber@gmx.de>2013-04-30 15:40:56 (GMT)
commit8d03d2cf7e572b65cd242a44081b514338e4fd6b (patch)
treef1ae136ef3e83aca4ab7fcbdd400e0275c6e8c1d /src/deps_log.h
parentbc56367850a0c826b9d08ad3efc262af1b872b9f (diff)
downloadNinja-8d03d2cf7e572b65cd242a44081b514338e4fd6b.zip
Ninja-8d03d2cf7e572b65cd242a44081b514338e4fd6b.tar.gz
Ninja-8d03d2cf7e572b65cd242a44081b514338e4fd6b.tar.bz2
Move some DepsLog::Deps initialization code into its constructor.
No functionality change.
Diffstat (limited to 'src/deps_log.h')
-rw-r--r--src/deps_log.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/deps_log.h b/src/deps_log.h
index 4b357a8..820997e 100644
--- a/src/deps_log.h
+++ b/src/deps_log.h
@@ -72,7 +72,8 @@ struct DepsLog {
// Reading (startup-time) interface.
struct Deps {
- Deps() : mtime(-1), node_count(0), nodes(NULL) {}
+ Deps(int mtime, int node_count)
+ : mtime(mtime), node_count(node_count), nodes(new Node*[node_count]) {}
~Deps() { delete [] nodes; }
int mtime;
int node_count;