Subversion Repositories Kolibri OS

Rev

Rev 5598 | Rev 5631 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5598 Rev 5626
Line 1... Line 1...
1
#ifndef INCLUDE_DLL_H
1
#ifndef INCLUDE_DLL_H
2
#define INCLUDE_DLL_H
2
#define INCLUDE_DLL_H
Line -... Line 3...
-
 
3
 
-
 
4
#ifndef INCLUDE_KOLIBRI_H
-
 
5
#include "../lib/file_system.h"
-
 
6
#endif
-
 
7
 
3
 
8
 
Line 4... Line 9...
4
char a_libdir[43]  = "/sys/lib/\0";
9
char a_libdir[43]  = "/sys/lib/\0";
5
 
10
 
6
:inline void error_init(dword text)
-
 
7
{
11
:inline void error_init(dword text)
8
	dword l,ll;
12
{
9
	dword TEXT_ERROR = malloc(1024);
13
	dword TEXT_ERROR = malloc(1024);
10
	#ifdef LANG_RUS
14
	#ifdef LANG_RUS
11
		strcpy(TEXT_ERROR,"'Žè¨¡ª  ¯à¨ § £à㧪¥ ¡¨¡«¨®â¥ª¨ `");
15
		strcpy(TEXT_ERROR,"'Žè¨¡ª  ¯à¨ § £à㧪¥ ¡¨¡«¨®â¥ª¨ `");
12
	#elif LANG_EST
16
	#elif LANG_EST
13
		strcpy(TEXT_ERROR,"'Viga teegi laadimisel `");
17
		strcpy(TEXT_ERROR,"'Viga teegi laadimisel `");
14
	#else
18
	#else
15
		strcpy(TEXT_ERROR,"'Error while loading library `");
-
 
16
	#endif
19
		strcpy(TEXT_ERROR,"'Error while loading library `");
17
	ll = strlen(TEXT_ERROR);
-
 
18
	strcpy(TEXT_ERROR+ll,text);
20
	#endif
19
	l = strlen(text);
21
	strcat(TEXT_ERROR,text);
20
	strncpy(TEXT_ERROR+ll+l,"`' -E",4);
22
	strcat(TEXT_ERROR,"`' -E");
21
	notify(TEXT_ERROR);
-
 
22
	free(TEXT_ERROR);
23
	notify(TEXT_ERROR);
Line 23... Line 24...
23
	ExitProcess();
24
	free(TEXT_ERROR);
24
}
25
}
25
 
26
 
Line 234... Line 235...
234
@import_done01:
235
@import_done01:
235
        IF (need_init) dll_Init (DSDWORD[EDX+4]);
236
        IF (need_init) dll_Init (DSDWORD[EDX+4]);
236
        return 0;
237
        return 0;
237
@exit01:
238
@exit01:
238
        return -1;
239
        return -1;
-
 
240
}
-
 
241
 
-
 
242
void load_dll(dword dllname, import_table, byte need_init)
-
 
243
{
239
		//error_init(dllname);
244
	if (load_dll2(dllname, import_table, need_init)!=0) error_init(dllname);
240
}
245
}
Line 241... Line 246...
241
 
246
 
242
 
247