Skip to content

Commit 1b6b631

Browse files
committed
Use make_unique to create unique ptr
1 parent ca7c0ae commit 1b6b631

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tools/rules-check/rules-check.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ void print_help(const char *name) {
3232

3333

3434
int main(int argc, char **argv) {
35-
std::unique_ptr<modsecurity::RulesSet> rules (new modsecurity::RulesSet());
35+
std::unique_ptr<modsecurity::RulesSet> rules = std::make_unique<modsecurity::RulesSet>();
3636
char **args = argv;
3737
int ret = 0;
3838

@@ -45,7 +45,7 @@ int main(int argc, char **argv) {
4545

4646
while (*args != NULL) {
4747
struct stat buffer;
48-
std::string arg = (*args);
48+
std::string arg = *args;
4949
std::string err;
5050
int r;
5151

0 commit comments

Comments
 (0)