Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(47)

Unified Diff: libiberty/regex.c

Issue 124383005: GDB 7.6.50 (Closed) Base URL: http://git.chromium.org/native_client/nacl-gdb.git@upstream
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « libiberty/pex-win32.c ('k') | libiberty/sha1.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: libiberty/regex.c
diff --git a/libiberty/regex.c b/libiberty/regex.c
index d65eedb16704313a58f293c0c9e00600e51a29a2..c11f330273ddd34c019bf120a02e43dc5872da9d 100644
--- a/libiberty/regex.c
+++ b/libiberty/regex.c
@@ -4,7 +4,7 @@
internationalization features.)
Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
- 2002, 2005, 2010 Free Software Foundation, Inc.
+ 2002, 2005, 2010, 2013 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -46,9 +46,11 @@
# if defined STDC_HEADERS && !defined emacs
# include <stddef.h>
+# define PTR_INT_TYPE ptrdiff_t
# else
/* We need this for `regex.h', and perhaps for the Emacs include files. */
# include <sys/types.h>
+# define PTR_INT_TYPE long
# endif
# define WIDE_CHAR_SUPPORT (HAVE_WCTYPE_H && HAVE_WCHAR_H && HAVE_BTOWC)
@@ -2045,7 +2047,7 @@ static reg_errcode_t byte_compile_range (unsigned int range_start,
/* How many characters the new buffer can have? */ \
wchar_count = bufp->allocated / sizeof(UCHAR_T); \
if (wchar_count == 0) wchar_count = 1; \
- /* Truncate the buffer to CHAR_T align. */ \
+ /* Truncate the buffer to CHAR_T align. */ \
bufp->allocated = wchar_count * sizeof(UCHAR_T); \
RETALLOC (COMPILED_BUFFER_VAR, wchar_count, UCHAR_T); \
bufp->buffer = (char*)COMPILED_BUFFER_VAR; \
@@ -2054,7 +2056,7 @@ static reg_errcode_t byte_compile_range (unsigned int range_start,
/* If the buffer moved, move all the pointers into it. */ \
if (old_buffer != COMPILED_BUFFER_VAR) \
{ \
- int incr = COMPILED_BUFFER_VAR - old_buffer; \
+ PTR_INT_TYPE incr = COMPILED_BUFFER_VAR - old_buffer; \
MOVE_BUFFER_POINTER (b); \
MOVE_BUFFER_POINTER (begalt); \
if (fixup_alt_jump) \
@@ -2082,7 +2084,7 @@ static reg_errcode_t byte_compile_range (unsigned int range_start,
/* If the buffer moved, move all the pointers into it. */ \
if (old_buffer != COMPILED_BUFFER_VAR) \
{ \
- int incr = COMPILED_BUFFER_VAR - old_buffer; \
+ PTR_INT_TYPE incr = COMPILED_BUFFER_VAR - old_buffer; \
MOVE_BUFFER_POINTER (b); \
MOVE_BUFFER_POINTER (begalt); \
if (fixup_alt_jump) \
@@ -3394,7 +3396,7 @@ PREFIX(regex_compile) (const char *ARG_PREFIX(pattern),
class. */
PATFETCH (c);
- /* Now we have to go throught the whole table
+ /* Now we have to go through the whole table
and find all characters which have the same
first level weight.
« no previous file with comments | « libiberty/pex-win32.c ('k') | libiberty/sha1.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698