summaryrefslogtreecommitdiff
path: root/ext/syslog/syslog.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/syslog/syslog.c')
-rw-r--r--ext/syslog/syslog.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/syslog/syslog.c b/ext/syslog/syslog.c
index 477489ddfe..d4945ae7b4 100644
--- a/ext/syslog/syslog.c
+++ b/ext/syslog/syslog.c
@@ -32,7 +32,7 @@ static void syslog_write(int pri, int argc, VALUE *argv)
str = rb_f_sprintf(argc, argv);
- syslog(pri, "%s", RSTRING(str)->ptr);
+ syslog(pri, "%s", RSTRING_PTR(str));
}
/* Syslog module methods */
@@ -70,7 +70,7 @@ static VALUE mSyslog_open(int argc, VALUE *argv, VALUE self)
#else
Check_SafeStr(ident);
#endif
- syslog_ident = strdup(RSTRING(ident)->ptr);
+ syslog_ident = strdup(RSTRING_PTR(ident));
if (NIL_P(opt)) {
syslog_options = LOG_PID | LOG_CONS;