Author: sedwards
Date: Wed Feb 4 04:01:42 2009
New Revision: 39383
URL:
http://svn.reactos.org/svn/reactos?rev=39383&view=rev
Log:
Warning cleanup:
- disable the unused service related functions for now
- comment out a bunch of unused variables
- cast a few things to shut up compiler warnings for now
Modified:
trunk/rosapps/applications/sysutils/telnetd/serviceentry.c
trunk/rosapps/applications/sysutils/telnetd/telnetd.c
Modified: trunk/rosapps/applications/sysutils/telnetd/serviceentry.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/sysutils/teln…
==============================================================================
--- trunk/rosapps/applications/sysutils/telnetd/serviceentry.c [iso-8859-1] (original)
+++ trunk/rosapps/applications/sysutils/telnetd/serviceentry.c [iso-8859-1] Wed Feb 4
04:01:42 2009
@@ -20,7 +20,7 @@
/* FUNCTIONS *****************************************************************/
-
+#if 0
static DWORD WINAPI
ServiceControlHandler(DWORD dwControl,
DWORD dwEventType,
@@ -54,7 +54,7 @@
DPRINT("ServiceMain() done\n");
}
-
+#endif
int
main(int argc, CHAR *argv[])
@@ -73,8 +73,7 @@
StartServiceCtrlDispatcher(ServiceTable);
#endif
-
- telnetd_main();
+ telnetd_main();
DPRINT("TelnetD: main() done\n");
@@ -84,3 +83,4 @@
}
/* EOF */
+
Modified: trunk/rosapps/applications/sysutils/telnetd/telnetd.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/sysutils/teln…
==============================================================================
--- trunk/rosapps/applications/sysutils/telnetd/telnetd.c [iso-8859-1] (original)
+++ trunk/rosapps/applications/sysutils/telnetd/telnetd.c [iso-8859-1] Wed Feb 4 04:01:42
2009
@@ -89,7 +89,7 @@
static int DoTelnetHandshake(int sock);
static int ReceiveLine(int sock, char *buffer, int len, EchoMode echo);
static void RunShell(client_t *client);
-static BOOL CreateChildProcess(const char *);
+//static BOOL CreateChildProcess(const char *);
static DWORD WINAPI MonitorChildThread(LPVOID);
static DWORD WINAPI WriteToPipeThread(LPVOID);
static DWORD WINAPI ReadFromPipeThread(LPVOID);
@@ -224,8 +224,8 @@
char welcome[256];
char hostname[64] = "Unknown";
char *pwdPrompt = "\r\npass:";
- char *logonPrompt = "\r\nLogin OK, please wait...";
- char *byebye = "\r\nWrong! bye bye...\r\n";
+ //char *logonPrompt = "\r\nLogin OK, please wait...";
+ //char *byebye = "\r\nWrong! bye bye...\r\n";
char userID[USERID_SIZE];
char password[USERID_SIZE];
int received;
@@ -321,7 +321,7 @@
return 0;
}
/* no error and no timeout, we have data in our sock */
- received = recv(sock, client_reply, sizeof(client_reply), 0);
+ received = recv(sock, (char *) client_reply, sizeof(client_reply), 0);
if (received <= 0) {
return -1;
}
@@ -466,7 +466,7 @@
NULL, // process security attributes
NULL, // primary thread security attributes
TRUE, // handles are inherited
- //DETACHED_PROCESS + // creation flags
+ DETACHED_PROCESS + // creation flags
CREATE_NEW_PROCESS_GROUP,
NULL, // use parent's environment
NULL, // use parent's current directory
@@ -507,7 +507,7 @@
WaitForSingleObject(client->hProcess, INFINITE);
GetExitCodeProcess(client->hProcess, &exitCode);
- printf("Child process terminated with code %d\n", exitCode);
+ printf("Child process terminated with code %lx\n", exitCode);
/* signal the other threads to give up */
client->bTerminate = TRUE;
@@ -589,7 +589,7 @@
CHAR chBuf[BUFSIZE];
CHAR txBuf[BUFSIZE*2];
DWORD from,to;
- char warning[] = "warning: rl_prep_terminal: cannot get terminal settings";
+ //char warning[] = "warning: rl_prep_terminal: cannot get terminal
settings";
client_t *client = (client_t *) data;