libxlsxwriter/src/format.c in fast_excel-0.2.6 vs libxlsxwriter/src/format.c in fast_excel-0.3.0

- old
+ new

@@ -1,11 +1,11 @@ /***************************************************************************** * format - A library for creating Excel XLSX format files. * * Used in conjunction with the libxlsxwriter library. * - * Copyright 2014-2018, John McNamara, jmcnamara@cpan.org. See LICENSE.txt. + * Copyright 2014-2019, John McNamara, jmcnamara@cpan.org. See LICENSE.txt. * */ #include "xlsxwriter/xmlwriter.h" #include "xlsxwriter/format.h" @@ -19,11 +19,11 @@ /* * Create a new format object. */ lxw_format * -lxw_format_new() +lxw_format_new(void) { lxw_format *format = calloc(1, sizeof(lxw_format)); GOTO_LABEL_ON_MEM_ERROR(format, mem_error); format->xf_format_indices = NULL; @@ -453,10 +453,10 @@ { /* Convert user angle to Excel angle. */ if (angle == 270) { self->rotation = 255; } - else if (angle >= -90 || angle <= 90) { + else if (angle >= -90 && angle <= 90) { if (angle < 0) angle = -angle + 90; self->rotation = angle; }