Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Removed unused code.

  • Loading branch information...
commit a7dabaad4cc994f6aa54d599d6824d119a9a3b41 1 parent 8ecb578
Mark Ellzey authored
Showing with 2 additions and 16 deletions.
  1. +0 −9 evhtp.c
  2. +2 −7 evthr/evthr.c
View
9 evhtp.c
@@ -2322,7 +2322,6 @@ evhtp_parse_query(const char * query, size_t len) {
char * val_buf = NULL;
int key_idx;
int val_idx;
- int res;
unsigned char ch;
size_t i;
@@ -2341,11 +2340,9 @@ evhtp_parse_query(const char * query, size_t len) {
val_idx = 0;
for (i = 0; i < len; i++) {
- res = 0;
ch = query[i];
if (key_idx >= len || val_idx >= len) {
- res = -1;
goto error;
}
@@ -2379,7 +2376,6 @@ evhtp_parse_query(const char * query, size_t len) {
state = s_query_question_mark;
break;
default:
- res = -1;
goto error;
}
break;
@@ -2405,7 +2401,6 @@ evhtp_parse_query(const char * query, size_t len) {
/* not hex, so we treat as a normal key */
if ((key_idx + 2) >= len) {
/* we need to insert \%<ch>, but not enough space */
- res = -1;
goto error;
}
@@ -2423,7 +2418,6 @@ evhtp_parse_query(const char * query, size_t len) {
break;
case s_query_key_hex_2:
if (!evhtp_is_hex_query_char(ch)) {
- res = -1;
goto error;
}
@@ -2465,7 +2459,6 @@ evhtp_parse_query(const char * query, size_t len) {
/* not really a hex val */
if ((val_idx + 2) >= len) {
/* we need to insert \%<ch>, but not enough space */
- res = -1;
goto error;
}
@@ -2485,7 +2478,6 @@ evhtp_parse_query(const char * query, size_t len) {
break;
case s_query_val_hex_2:
if (!evhtp_is_hex_query_char(ch)) {
- res = -1;
goto error;
}
@@ -2496,7 +2488,6 @@ evhtp_parse_query(const char * query, size_t len) {
break;
default:
/* bad state */
- res = -1;
goto error;
} /* switch */
}
View
9 evthr/evthr.c
@@ -407,10 +407,8 @@ evthr_pool_defer(evthr_pool_t * pool, evthr_cb cb, void * arg) {
/* find the thread with the smallest backlog */
TAILQ_FOREACH(thr, &pool->threads, next) {
- evthr_t * m_save;
- evthr_t * t_save;
- int thr_backlog = 0;
- int min_backlog = 0;
+ int thr_backlog = 0;
+ int min_backlog = 0;
thr_backlog = evthr_get_backlog(thr);
@@ -418,9 +416,6 @@ evthr_pool_defer(evthr_pool_t * pool, evthr_cb cb, void * arg) {
min_backlog = evthr_get_backlog(min_thr);
}
- m_save = min_thr;
- t_save = thr;
-
if (min_thr == NULL) {
min_thr = thr;
} else if (thr_backlog == 0) {
Please sign in to comment.
Something went wrong with that request. Please try again.