summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/bigdecimal/bigdecimal.c2
-rw-r--r--ext/digest/rmd160/rmd160ossl.c2
-rw-r--r--ext/digest/sha1/sha1ossl.c2
-rw-r--r--ext/readline/readline.c1
-rw-r--r--ext/syck/syck.c3
5 files changed, 6 insertions, 4 deletions
diff --git a/ext/bigdecimal/bigdecimal.c b/ext/bigdecimal/bigdecimal.c
index 4de56724570..eb0d2b390d4 100644
--- a/ext/bigdecimal/bigdecimal.c
+++ b/ext/bigdecimal/bigdecimal.c
@@ -13,6 +13,7 @@
*
*/
+#include "ruby.h"
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
@@ -20,7 +21,6 @@
#include <errno.h>
#include <float.h>
#include <math.h>
-#include "ruby.h"
#include "math.h"
#include "version.h"
diff --git a/ext/digest/rmd160/rmd160ossl.c b/ext/digest/rmd160/rmd160ossl.c
index be66d81ff99..2989ffd00e9 100644
--- a/ext/digest/rmd160/rmd160ossl.c
+++ b/ext/digest/rmd160/rmd160ossl.c
@@ -1,7 +1,7 @@
/* $Id$ */
-#include "rmd160ossl.h"
#include "defs.h"
+#include "rmd160ossl.h"
#include <assert.h>
#include <stdlib.h>
diff --git a/ext/digest/sha1/sha1ossl.c b/ext/digest/sha1/sha1ossl.c
index b125128f820..82a4f6f057e 100644
--- a/ext/digest/sha1/sha1ossl.c
+++ b/ext/digest/sha1/sha1ossl.c
@@ -1,7 +1,7 @@
/* $Id$ */
-#include "sha1ossl.h"
#include "defs.h"
+#include "sha1ossl.h"
#include <assert.h>
#include <stdlib.h>
diff --git a/ext/readline/readline.c b/ext/readline/readline.c
index f6dc6b67ed8..bc2241007fd 100644
--- a/ext/readline/readline.c
+++ b/ext/readline/readline.c
@@ -5,6 +5,7 @@
#include RUBY_EXTCONF_H
#endif
+#include "config.h"
#include <errno.h>
#include <stdio.h>
#include <ctype.h>
diff --git a/ext/syck/syck.c b/ext/syck/syck.c
index 20b124ab286..daf531632f7 100644
--- a/ext/syck/syck.c
+++ b/ext/syck/syck.c
@@ -412,7 +412,8 @@ syck_move_tokens( SyckParser *p )
skip = p->limit - p->token;
if ( ( count = p->token - p->buffer ) )
{
- S_MEMMOVE( p->buffer, p->token, char, skip );
+ if (skip > 0)
+ S_MEMMOVE( p->buffer, p->token, char, skip );
p->token = p->buffer;
p->marker -= count;
p->cursor -= count;