1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-11-04 08:17:17 -05:00

Revert "Compilation fix, a bit ugly."

This reverts commit c246b67ff9.
This commit is contained in:
Witold Filipczyk 2007-09-02 16:57:42 +02:00 committed by Witold Filipczyk
parent 5e145576b0
commit 1424002087

View File

@ -674,14 +674,12 @@ static struct mime_handler *
get_mime_handler_mailcap(unsigned char *type, struct terminal *term)
{
struct mime_handler *handler = NULL;
#if defined(HAVE_SYS_IPC_H) && defined(HAVE_SYS_SEM_H) && defined(HAVE_SYS_SHM_H)
unsigned char *desc, *data;
int block, len;
#endif
if (!term || term->master || slave_sem == -1)
return get_mime_handler_mailcap_common(type);
#if defined(HAVE_SYS_IPC_H) && defined(HAVE_SYS_SEM_H) && defined(HAVE_SYS_SHM_H)
len = strlen(type) + 1;
data = fmem_alloc(2 + len);
if (!data)
@ -691,7 +689,7 @@ get_mime_handler_mailcap(unsigned char *type, struct terminal *term)
memcpy(data + 2, type, len);
hard_write(term->fdout, data, len + 2);
fmem_free(data);
#if defined(HAVE_SYS_IPC_H) && defined(HAVE_SYS_SEM_H) && defined(HAVE_SYS_SHM_H)
if (!shared_mem)
return NULL;
shared_mem[0] = '\0'; /* For unexpected death of slave. */