"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/scanner.l" between
udunits-2.2.26.tar.gz and udunits-2.2.28.tar.gz

About: UDUNITS supports units of physical quantities. Its C library provides for arithmetic manipulation of units and for conversion of numeric values between compatible units.

scanner.l  (udunits-2.2.26):scanner.l  (udunits-2.2.28)
skipping to change at line 18 skipping to change at line 18
/* /*
* lex(1) specification for tokens for the Unidata units package, UDUNITS2. * lex(1) specification for tokens for the Unidata units package, UDUNITS2.
*/ */
%option noyywrap %option noyywrap
%{ %{
#include <ctype.h> #include <ctype.h>
#include <errno.h> #include <errno.h>
#include <limits.h>
#include <math.h> #include <math.h>
#include <stddef.h> #include <stddef.h>
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include <time.h> #include <time.h>
/** /**
* Decodes a date. * Decodes a date.
* *
skipping to change at line 213 skipping to change at line 214
{"\xc2\xb2", 2}, /* 2 */ {"\xc2\xb2", 2}, /* 2 */
{"\xc2\xb3", 2}, /* 3 */ {"\xc2\xb3", 2}, /* 3 */
{"\xe2\x81\xb4", 3}, /* 4 */ {"\xe2\x81\xb4", 3}, /* 4 */
{"\xe2\x81\xb5", 3}, /* 5 */ {"\xe2\x81\xb5", 3}, /* 5 */
{"\xe2\x81\xb6", 3}, /* 6 */ {"\xe2\x81\xb6", 3}, /* 6 */
{"\xe2\x81\xb7", 3}, /* 7 */ {"\xe2\x81\xb7", 3}, /* 7 */
{"\xe2\x81\xb8", 3}, /* 8 */ {"\xe2\x81\xb8", 3}, /* 8 */
{"\xe2\x81\xb9", 3}, /* 9 */ {"\xe2\x81\xb9", 3}, /* 9 */
}; };
if (exponent > INT_MAX/10) {
status = ERR;
break;
}
exponent *= 10; exponent *= 10;
for (j = 0; j < 10; j++) { for (j = 0; j < 10; j++) {
int len = utf8_exponents[j].len; int len = utf8_exponents[j].len;
if (strncmp(cp, utf8_exponents[j].string, len) == 0) { if (strncmp(cp, utf8_exponents[j].string, len) == 0) {
exponent += j; exponent += j;
cp += len; cp += len;
break; break;
} }
 End of changes. 2 change blocks. 
0 lines changed or deleted 6 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)