Stop using C++ style comments.

svn:r1343
This commit is contained in:
Nick Mathewson 2009-07-14 18:50:06 +00:00
parent e224321c64
commit 043515bc52
7 changed files with 19 additions and 18 deletions

View File

@ -1773,9 +1773,11 @@ evthread_make_base_notifiable(struct event_base *base)
base->th_notify_fn = notify; base->th_notify_fn = notify;
// This can't be right, can it? We want writes to this socket to /*
// just succeed. This can't be right, can it? We want writes to this socket to
// evutil_make_socket_nonblocking(base->th_notify_fd[1]); just succeed.
evutil_make_socket_nonblocking(base->th_notify_fd[1]);
*/
/* prepare an event that we can use for wakeup */ /* prepare an event that we can use for wakeup */
event_assign(&base->th_notify, base, base->th_notify_fd[0], event_assign(&base->th_notify, base, base->th_notify_fd[0],

View File

@ -561,7 +561,7 @@ evutil_inet_pton(int af, const char *src, void *dst)
if (gapPos >= 0) { if (gapPos >= 0) {
int nToMove = setWords - (dot ? 2 : 0) - gapPos; int nToMove = setWords - (dot ? 2 : 0) - gapPos;
int gapLen = 8 - setWords; int gapLen = 8 - setWords;
// assert(nToMove >= 0); /* assert(nToMove >= 0); */
if (nToMove < 0) if (nToMove < 0)
return -1; /* should be impossible */ return -1; /* should be impossible */
memmove(&words[gapPos+gapLen], &words[gapPos], memmove(&words[gapPos+gapLen], &words[gapPos],

View File

@ -42,7 +42,7 @@ fifo_read(int fd, short event, void *arg)
#ifdef WIN32 #ifdef WIN32
len = ReadFile((HANDLE)fd, buf, sizeof(buf) - 1, &dwBytesRead, NULL); len = ReadFile((HANDLE)fd, buf, sizeof(buf) - 1, &dwBytesRead, NULL);
// Check for end of file. /* Check for end of file. */
if(len && dwBytesRead == 0) { if(len && dwBytesRead == 0) {
fprintf(stderr, "End Of File"); fprintf(stderr, "End Of File");
event_del(ev); event_del(ev);
@ -72,14 +72,14 @@ main (int argc, char **argv)
struct event evfifo; struct event evfifo;
#ifdef WIN32 #ifdef WIN32
HANDLE socket; HANDLE socket;
// Open a file. /* Open a file. */
socket = CreateFile("test.txt", // open File socket = CreateFile("test.txt", /* open File */
GENERIC_READ, // open for reading GENERIC_READ, /* open for reading */
0, // do not share 0, /* do not share */
NULL, // no security NULL, /* no security */
OPEN_EXISTING, // existing file only OPEN_EXISTING, /* existing file only */
FILE_ATTRIBUTE_NORMAL, // normal file FILE_ATTRIBUTE_NORMAL, /* normal file */
NULL); // no attr. template NULL); /* no attr. template */
if(socket == INVALID_HANDLE_VALUE) if(socket == INVALID_HANDLE_VALUE)
return 1; return 1;

View File

@ -1135,7 +1135,7 @@ test_evbuffer_freeze(void *ptr)
FREEZE_EQ(r, 0, -1); FREEZE_EQ(r, 0, -1);
r = evbuffer_add_printf(buf, "Hello %s", "world"); r = evbuffer_add_printf(buf, "Hello %s", "world");
FREEZE_EQ(r, 11, -1); FREEZE_EQ(r, 11, -1);
// TODO: test add_buffer, add_file, read /* TODO: test add_buffer, add_file, read */
if (!start) if (!start)
tt_int_op(orig_length, ==, evbuffer_get_length(buf)); tt_int_op(orig_length, ==, evbuffer_get_length(buf));
@ -1153,7 +1153,7 @@ test_evbuffer_freeze(void *ptr)
FREEZE_EQ(cp==NULL, 1, 0); FREEZE_EQ(cp==NULL, 1, 0);
if (cp) if (cp)
free(cp); free(cp);
// TODO: Test remove_buffer, add_buffer, write, prepend_buffer /* TODO: Test remove_buffer, add_buffer, write, prepend_buffer */
if (start) if (start)
tt_int_op(orig_length, ==, evbuffer_get_length(buf)); tt_int_op(orig_length, ==, evbuffer_get_length(buf));

View File

@ -1112,7 +1112,7 @@ http_put_cb(struct evhttp_request *req, void *arg)
if (EVBUFFER_LENGTH(req->input_buffer) != strlen(PUT_DATA)) { if (EVBUFFER_LENGTH(req->input_buffer) != strlen(PUT_DATA)) {
fprintf(stdout, "FAILED (length: %zu vs %zu)\n", fprintf(stdout, "FAILED (length: %zu vs %zu)\n",
EVBUFFER_LENGTH(req->input_buffer), strlen(PUT_DATA)); EVBUFFER_LENGTH(req->input_buffer), strlen(PUT_DATA));
//exit(1); exit(1);
} }
if (memcmp(EVBUFFER_DATA(req->input_buffer), PUT_DATA, if (memcmp(EVBUFFER_DATA(req->input_buffer), PUT_DATA,

View File

@ -150,7 +150,7 @@ basic_test_setup(const struct testcase_t *testcase)
if (testcase->flags & TT_NEED_DNS) { if (testcase->flags & TT_NEED_DNS) {
evdns_set_log_fn(dnslogcb); evdns_set_log_fn(dnslogcb);
if (evdns_init()) if (evdns_init())
return NULL; /* fast failure *//*XXX asserts. */ return NULL; /* fast failure */ /*XXX asserts. */
} }
data = calloc(1, sizeof(*data)); data = calloc(1, sizeof(*data));

View File

@ -102,7 +102,6 @@ _testcase_run_forked(const struct testgroup_t *group,
*/ */
int ok; int ok;
char buffer[LONGEST_TEST_NAME+256]; char buffer[LONGEST_TEST_NAME+256];
//const char *verbosity;
STARTUPINFO si; STARTUPINFO si;
PROCESS_INFORMATION info; PROCESS_INFORMATION info;
DWORD exitcode; DWORD exitcode;