Parolin 0.7.9 6796
Console (soon DLLs) to do a tar like job
Loading...
Searching...
No Matches
brotli2_thread.c
Go to the documentation of this file.
1/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2
3 #2023 X March 21 19:50 PM Brasília Time
4
5* *
6* Licensa de Copia (C) <2023> <Aurora Boreal> *
7* *
8* Este programa e software livre: voce pode redistribuir isto e/ou *
9* modificar isto sobre os termos do GNU Licensa Geral Pública como 25
10* publicado pela Fundacao de Software Livre, tanto a versão 3 da *
11* Licensa, ou (dependendo da sua opcao) qualquer versao posterior. *
12* *
13* Este programa e distribuido na esperanca que isto vai ser util, *
14* mas SEM QUALQUER GARANTIA; sem ate mesmo a implicada garantia de *
15* COMERCIALIZAcaO ou CABIMENTO PARA UM FIM PARTICULAR. Veja a *
16* Licensa Geral Publica para mais detalhes. *
17* *
18* Você deve ter recebido uma cópia da LICENSA GERAL PUBLICA e a GNU *
19* Licensa Publica Menor junto com este programa *
20* Se não, veja <http://www.gnu.org/licenses/>. *
21* *
22* Suporte: sourceforge.net github.com *
23* *
24* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
25
26* Pereira: arsoftware25@gmail.com ricardo@arsoftware.net.br *
27* xcx: arsoftware10@gmail.com charli@arsoftware.net.br *
28 Yasmin: yasmin@arsoftware.net.br *
29 pereira1001@users.sourceforge.net
30 */
31
32
34
35unsigned __stdcall my_thread_function_v27_7(void * my_argument_z )
36{
37
38 void
40 (
41 int amanda_level,
42 char *format, ...
43 );
44
46 my_thread_struct_z * ptr_my_struct_z = (void *) my_argument_z;
47 assert(ptr_my_struct_z);
48 if(NULL == ptr_my_struct_z->dest)
49 {
50 goto saida_amanda;
51 }
52
53 pedro_dprintf(-1, "bytes to extract %lld\n", ptr_my_struct_z->size_of_input_file_copy_z);
54
55 /*
56 if(0 != ptr_my_struct_z->offset_z)
57 {
58
59 pedro_dprintf(-1, "seek to %lld\n", ptr_my_struct_z->offset_z);
60
61 if(
62 0 != _fseeki64(
63 ptr_my_struct_z->input_file,
64 ptr_my_struct_z->offset_z,
65 SEEK_SET
66 )
67 )
68 {
69 ptr_my_struct_z->retvalue = 403; //File access error
70 goto saida_amanda;
71 }
72 }
73 */
74
75 //aqui amor...
76
77 ptr_my_struct_z->dest_is_FILE_z = true;
78
79 ptr_my_struct_z->retvalue = zuncompress_sha512_k_mt_decoding_multi_thread_z_7(ptr_my_struct_z->input_file, NULL, ptr_my_struct_z);
80
81 if(119 == ptr_my_struct_z->internal_error_arp)
82 {
83 ptr_my_struct_z->retvalue = 119;
84 }
85 else if(6 == ptr_my_struct_z->internal_error_arp)
86 {
87 ptr_my_struct_z->retvalue = ptr_my_struct_z->internal_error_arp;
88 }
89 else
90 {
91 if(ptr_my_struct_z->retvalue)
92 {
93 pedro_dprintf(-1, "error 2 7 \n");
94 ptr_my_struct_z->retvalue = 7; //Decompression error
95 }
96 }
97
98saida_amanda:;
99
100 if (*(ptr_my_struct_z->intcancel_7))
101 {
102 ptr_my_struct_z->retvalue = 119;//User abort
103 }
104
105 if(ptr_my_struct_z->input_file )
106 {
107 fclose(ptr_my_struct_z->input_file);
108 }
109 if(ptr_my_struct_z->dest)
110 {
111 fclose(ptr_my_struct_z->dest);
112 ptr_my_struct_z->dest = NULL;
113 }
115 {
116 thread_return_value_z_7 = ptr_my_struct_z->retvalue;
117 }
118
119 //Sleep(2000);
120
121 free(my_argument_z);
122 _endthreadex(0);
123
124 return 27+51;
125}
void pedro_dprintf(int amanda_level, char *format,...)
Definition pedro.c:43
int thread_return_value_z_7
Definition brotli2.c:292
int zuncompress_sha512_k_mt_decoding_multi_thread_z_7(FILE *source, FILE *dest, my_thread_struct_z *amanda)
Definition brotli2_decoder_mt_z.c:34
unsigned __stdcall my_thread_function_v27_7(void *my_argument_z)
Definition brotli2_thread.c:35
#define assert(condition)
Definition lz4.c:273
const char * source
Definition lz4.h:808
char * dest
Definition lz4.h:806
void yasmin_charlotte_pereira_dprintf(int amanda_level, char *format,...)
Definition pedro.c:35
Definition stdio_v3.h:23
int64_t size_of_input_file_copy_z
Definition stdio_v3.h:46
int retvalue
Definition stdio_v3.h:39
bool dest_is_FILE_z
Definition stdio_v3.h:32
int * intcancel_7
Definition stdio_v3.h:41
FILE * dest
Definition stdio_v3.h:26
int internal_error_arp
Definition stdio_v3.h:36
FILE * input_file
Definition stdio_v3.h:35
#define NULL
Definition getopt1.c:37