* syntax.c: Remove all references to MAD.
Этот коммит содержится в:
родитель
e2a37d3809
Коммит
d6a8671055
@ -1,5 +1,7 @@
|
|||||||
2002-08-01 Pavel Roskin <proski@gnu.org>
|
2002-08-01 Pavel Roskin <proski@gnu.org>
|
||||||
|
|
||||||
|
* syntax.c: Remove all references to MAD.
|
||||||
|
|
||||||
* edit.h: Don't include mad.h.
|
* edit.h: Don't include mad.h.
|
||||||
|
|
||||||
2002-07-29 Andrew V. Samoilov <kai@cmail.ru>
|
2002-07-29 Andrew V. Samoilov <kai@cmail.ru>
|
||||||
|
@ -45,19 +45,10 @@
|
|||||||
int option_syntax_highlighting = 1;
|
int option_syntax_highlighting = 1;
|
||||||
int option_auto_spellcheck = 1;
|
int option_auto_spellcheck = 1;
|
||||||
|
|
||||||
#ifdef HAVE_MAD
|
static inline void *syntax_malloc (size_t x)
|
||||||
static void *mad_syntax_malloc (size_t x, char *file, int line)
|
|
||||||
#define syntax_malloc(x) mad_syntax_malloc (x, __FILE__, __LINE__)
|
|
||||||
#else
|
|
||||||
static void *syntax_malloc (size_t x)
|
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
void *p;
|
void *p;
|
||||||
#ifdef HAVE_MAD
|
|
||||||
p = mad_alloc (x, file, line);
|
|
||||||
#else
|
|
||||||
p = malloc (x);
|
p = malloc (x);
|
||||||
#endif
|
|
||||||
memset (p, 0, x);
|
memset (p, 0, x);
|
||||||
return p;
|
return p;
|
||||||
}
|
}
|
||||||
@ -391,11 +382,7 @@ static int read_one_line (char **line, FILE * f)
|
|||||||
{
|
{
|
||||||
char *p;
|
char *p;
|
||||||
int len = 256, c, r = 0, i = 0;
|
int len = 256, c, r = 0, i = 0;
|
||||||
#ifdef HAVE_MAD
|
|
||||||
p = mad_syntax_malloc (len, file, line_);
|
|
||||||
#else
|
|
||||||
p = syntax_malloc (len);
|
p = syntax_malloc (len);
|
||||||
#endif
|
|
||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
c = fgetc (f);
|
c = fgetc (f);
|
||||||
|
Загрузка…
Ссылка в новой задаче
Block a user