From bb7a97209bf64cf9cdc4ec9ecd0504179a8c22af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20Mart=C3=ADn?= Date: Mon, 8 Sep 2014 17:53:29 +0200 Subject: [PATCH] Feature #3175: Make sec groups start with ID 100 --- src/secgroup/SecurityGroupPool.cc | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/secgroup/SecurityGroupPool.cc b/src/secgroup/SecurityGroupPool.cc index 75a0d38bef..4d20eef7f7 100644 --- a/src/secgroup/SecurityGroupPool.cc +++ b/src/secgroup/SecurityGroupPool.cc @@ -20,7 +20,18 @@ SecurityGroupPool::SecurityGroupPool(SqlDB * db) :PoolSQL(db, SecurityGroup::table, true, true) -{} +{ + //lastOID is set in PoolSQL::init_cb + if (get_lastOID() == -1) + { + // The first 100 IDs are reserved for system Security Groups. + // Regular ones start from ID 100 + + set_update_lastOID(99); + } + + return; +} /* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */