Skip to content

Commit

Permalink
Fixed problem with SINGLE MODE and thread count = 0. #163
Browse files Browse the repository at this point in the history
  • Loading branch information
lexborisov committed Nov 14, 2018
1 parent b3b99ee commit 5243d39
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion source/myhtml/myhtml.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,11 @@ mystatus_t myhtml_init(myhtml_t* myhtml, enum myhtml_options opt, size_t thread_
#else /* if undef MyCORE_BUILD_WITHOUT_THREADS */
if(status)
return status;


if(thread_count == 0) {
thread_count = 1;
}

switch (opt) {
case MyHTML_OPTIONS_PARSE_MODE_SINGLE:
if((status = myhtml_create_stream_and_batch(myhtml, 0, 0)))
Expand Down

0 comments on commit 5243d39

Please sign in to comment.