Sisyphus repositório
Última atualização: 1 outubro 2023 | SRPMs: 18631 | Visitas: 37723417
en ru br
ALT Linux repositórios
S:1.1.1u-alt3

Group :: Sistema/Base
RPM: openssl1.1

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs e FR  Repocop 

Patch: openssl-alt-e2k-makecontext.patch
Download


diff --git a/openssl/crypto/async/arch/async_posix.c b/openssl/crypto/async/arch/async_posix.c
index 95678d4f..edf7441f 100644
--- a/openssl/crypto/async/arch/async_posix.c
+++ b/openssl/crypto/async/arch/async_posix.c
@@ -40,8 +40,17 @@ int async_fibre_makecontext(async_fibre *fibre)
         if (fibre->fibre.uc_stack.ss_sp != NULL) {
             fibre->fibre.uc_stack.ss_size = STACKSIZE;
             fibre->fibre.uc_link = NULL;
+#ifndef __e2k__
             makecontext(&fibre->fibre, async_start_func, 0);
             return 1;
+#else
+            if (makecontext_e2k(&fibre->fibre, async_start_func, 0) == 0)
+                return 1;
+            else {
+                OPENSSL_free(fibre->fibre.uc_stack.ss_sp);
+                fibre->fibre.uc_stack.ss_sp = NULL;
+            }
+#endif
         }
     } else {
         fibre->fibre.uc_stack.ss_sp = NULL;
@@ -51,6 +60,9 @@ int async_fibre_makecontext(async_fibre *fibre)
 
 void async_fibre_free(async_fibre *fibre)
 {
+#ifdef __e2k__
+    freecontext_e2k(&fibre->fibre);
+#endif
     OPENSSL_free(fibre->fibre.uc_stack.ss_sp);
     fibre->fibre.uc_stack.ss_sp = NULL;
 }
 
projeto & código: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
mantenedor atual: Michael Shigorin
mantenedor da tradução: Fernando Martini aka fmartini © 2009