Skip to content

Commit 8aa8811

Browse files
committed
Remove useless code
1 parent e1e0312 commit 8aa8811

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

src/webserver.cpp

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -534,12 +534,6 @@ bool webserver::start(bool blocking)
534534

535535
iov.push_back(gen(MHD_OPTION_END, 0, NULL ));
536536

537-
struct MHD_OptionItem ops[iov.size()];
538-
for(unsigned int i = 0; i < iov.size(); i++)
539-
{
540-
ops[i] = iov[i];
541-
}
542-
543537
int start_conf = start_method;
544538
if(use_ssl)
545539
start_conf |= MHD_USE_SSL;
@@ -563,7 +557,7 @@ bool webserver::start(bool blocking)
563557
(
564558
start_conf, this->port, &policy_callback, this,
565559
&answer_to_connection, this, MHD_OPTION_ARRAY,
566-
ops, MHD_OPTION_END
560+
&iov[0], MHD_OPTION_END
567561
);
568562
if(NULL == daemon)
569563
{
@@ -595,7 +589,7 @@ bool webserver::start(bool blocking)
595589
(
596590
start_conf, this->port, &policy_callback, this,
597591
&answer_to_connection, this, MHD_OPTION_ARRAY,
598-
ops, MHD_OPTION_END
592+
&iov[0], MHD_OPTION_END
599593
);
600594
if(NULL == daemon)
601595
{

0 commit comments

Comments
 (0)