403Webshell
Server IP : 82.208.35.60  /  Your IP : 216.73.216.168
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/comms/libfec/files/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/ports/comms/libfec/files/patch-encode__rs__8.c
--- encode_rs_8.c.orig	2019-02-06 10:40:06 UTC
+++ encode_rs_8.c
@@ -3,6 +3,7 @@
  * May be used under the terms of the GNU Lesser General Public License (LGPL)
  */
 #include <string.h>
+#include <sys/types.h>
 #include "fixed.h"
 #ifdef __VEC__
 #include <sys/sysctl.h>
@@ -36,10 +37,16 @@ void encode_rs_8(data_t *data, data_t *parity,int pad)
     }
 #elif __VEC__
     /* Ask the OS if we have Altivec support */
+#ifdef __APPLE__
     int selectors[2] = { CTL_HW, HW_VECTORUNIT };
+#endif
     int hasVectorUnit = 0;
     size_t length = sizeof(hasVectorUnit);
+#ifdef __APPLE__
     int error = sysctl(selectors, 2, &hasVectorUnit, &length, NULL, 0);
+#elif __FreeBSD__
+    int error = sysctlbyname("hw.altivec", &hasVectorUnit, &length, NULL, 0);
+#endif
     if(0 == error && hasVectorUnit)
       cpu_mode = ALTIVEC;
     else

Youez - 2016 - github.com/yon3zu
LinuXploit