mirror of
https://git.code.sf.net/p/zint/code
synced 2025-05-17 16:44:34 -04:00
Make compile with MS-VC6
This commit is contained in:
parent
7ae2e68396
commit
2cf489eac2
3 changed files with 7 additions and 3 deletions
|
@ -46,6 +46,10 @@
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#ifdef _MSC_VER
|
#ifdef _MSC_VER
|
||||||
#include <malloc.h>
|
#include <malloc.h>
|
||||||
|
/* ceilf (C99) not before MSVC++2013 (C++ 12.0) */
|
||||||
|
#if _MSC_VER < 1800
|
||||||
|
#define ceilf ceil
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
#include "reedsol.h"
|
#include "reedsol.h"
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
|
|
|
@ -38,10 +38,10 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include <stdint.h>
|
|
||||||
#ifndef _MSC_VER
|
#ifndef _MSC_VER
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#else
|
#else
|
||||||
|
#include "ms_stdint.h"
|
||||||
#include <malloc.h>
|
#include <malloc.h>
|
||||||
#endif
|
#endif
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
|
|
|
@ -272,7 +272,7 @@ int gif_pixel_plot(struct zint_symbol *symbol, char *pixelbuf) {
|
||||||
#ifndef _MSC_VER
|
#ifndef _MSC_VER
|
||||||
char lzwoutbuf[symbol->bitmap_height * symbol->bitmap_width];
|
char lzwoutbuf[symbol->bitmap_height * symbol->bitmap_width];
|
||||||
#else
|
#else
|
||||||
lzwoutbuf = (char *) _alloca((image_height * image_width) * sizeof (char));
|
lzwoutbuf = (char *) _alloca((symbol->bitmap_height * symbol->bitmap_width) * sizeof (char));
|
||||||
#endif /* _MSC_VER */
|
#endif /* _MSC_VER */
|
||||||
|
|
||||||
/* Open output file in binary mode */
|
/* Open output file in binary mode */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue