403Webshell
Server IP : 82.208.35.60  /  Your IP : 216.73.216.238
Web Server : Apache/2.4.55 (FreeBSD) OpenSSL/1.1.1q-freebsd PHP/7.3.31
System : FreeBSD server7.d2m.cz 12.4-RELEASE-p9 FreeBSD 12.4-RELEASE-p9 GENERIC amd64
User : studiokobylisy_cz ( 1008)
PHP Version : 7.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /usr/ports/sysutils/bkpupsd/files/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/ports/sysutils/bkpupsd/files/patch-src__bkpupsd.c
--- src/bkpupsd.c.orig	Sun Aug  3 20:11:23 1997
+++ src/bkpupsd.c	Fri Dec 15 00:53:52 2006
@@ -27,14 +27,17 @@
  */
 
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
 #include <fcntl.h>
 #include <err.h>
 #include <errno.h>
+#include <string.h>
 #include <sys/types.h>
 #include <sys/ioctl.h>
 #include <signal.h>
 #include <syslog.h>
-#include <varargs.h>
+#include <stdarg.h>
 
 #define POWER_TIMEOUT		5*60
 #define DEFAULT_PORT		"/dev/cuaa1"
@@ -44,16 +47,17 @@
 #define SH_RESTORED		"/usr/local/libexec/bkpupsd/bkpups.restored"
 #define SH_BATTLOW		"/usr/local/libexec/bkpupsd/bkpups.battlow"
 
+int makepid(char *s);
+void execomand();
+
 int main(argc, argv)
 int argc;
 char  **argv;
 {
 	int fd;
 	int lstatus;
-	int flags;
 	int rts_bit = TIOCM_RTS;
 	int dtr_bit = TIOCM_DTR;
-	int rng_bit = TIOCM_RNG;
 	int pfail = 0;
 	int pfcount = 0;
 	int prcount = 0;
@@ -63,7 +67,6 @@
 	char *sh_restored = SH_RESTORED;
 	char *sh_battlow  = SH_BATTLOW;
 	char *ups_port	  = DEFAULT_PORT;
-	static void execomand();
 
 		/* open ups port */
 	if(argc > 2) {
@@ -179,7 +182,7 @@
 	pid = getpid();
 	if((fp =  fopen(s, "w")) == NULL)
 		return -1;
-	fprintf(fp, "%ld\n", pid);
+	fprintf(fp, "%lu\n", (u_long)pid);
 	fclose(fp);
 	return 0;
 }

Youez - 2016 - github.com/yon3zu
LinuXploit