File tree Expand file tree Collapse file tree 3 files changed +31
-16
lines changed Expand file tree Collapse file tree 3 files changed +31
-16
lines changed Original file line number Diff line number Diff line change @@ -50,11 +50,11 @@ SEXP nano_encode(SEXP object) {
5050 break ;
5151 case STRSXP :
5252 for (i = 0 ; i < xlen ; i ++ )
53- outlen += strlen (Rf_translateChar0 (STRING_ELT (object , i ))) + 1 ;
53+ outlen += strlen (Rf_translateCharUTF8 (STRING_ELT (object , i ))) + 1 ;
5454 PROTECT (out = Rf_allocVector (RAWSXP , outlen ));
5555 buf = RAW (out );
5656 for (i = 0 , np = 0 ; i < xlen ; i ++ ) {
57- s = Rf_translateChar0 (STRING_ELT (object , i ));
57+ s = Rf_translateCharUTF8 (STRING_ELT (object , i ));
5858 memcpy (buf + np , s , strlen (s ) + 1 );
5959 np += strlen (s ) + 1 ;
6060 }
Original file line number Diff line number Diff line change 22
33#include "nanonext.h"
44
5+ SEXP nano_AioSymbol ;
6+ SEXP nano_ContextSymbol ;
7+ SEXP nano_DataSymbol ;
8+ SEXP nano_DialerSymbol ;
9+ SEXP nano_IdSymbol ;
10+ SEXP nano_ListenerSymbol ;
11+ SEXP nano_ProtocolSymbol ;
12+ SEXP nano_ResultSymbol ;
13+ SEXP nano_SocketSymbol ;
14+ SEXP nano_StateSymbol ;
15+ SEXP nano_StreamSymbol ;
16+ SEXP nano_TextframesSymbol ;
17+ SEXP nano_UnserSymbol ;
18+ SEXP nano_UrlSymbol ;
19+
520static void RegisterSymbols (void ) {
621 nano_AioSymbol = Rf_install ("aio" );
722 nano_ContextSymbol = Rf_install ("context" );
Original file line number Diff line number Diff line change @@ -42,20 +42,20 @@ extern void dialer_finalizer(SEXP);
4242extern void listener_finalizer (SEXP );
4343#endif
4444
45- SEXP nano_AioSymbol ;
46- SEXP nano_ContextSymbol ;
47- SEXP nano_DataSymbol ;
48- SEXP nano_DialerSymbol ;
49- SEXP nano_IdSymbol ;
50- SEXP nano_ListenerSymbol ;
51- SEXP nano_ProtocolSymbol ;
52- SEXP nano_ResultSymbol ;
53- SEXP nano_SocketSymbol ;
54- SEXP nano_StateSymbol ;
55- SEXP nano_StreamSymbol ;
56- SEXP nano_TextframesSymbol ;
57- SEXP nano_UnserSymbol ;
58- SEXP nano_UrlSymbol ;
45+ extern SEXP nano_AioSymbol ;
46+ extern SEXP nano_ContextSymbol ;
47+ extern SEXP nano_DataSymbol ;
48+ extern SEXP nano_DialerSymbol ;
49+ extern SEXP nano_IdSymbol ;
50+ extern SEXP nano_ListenerSymbol ;
51+ extern SEXP nano_ProtocolSymbol ;
52+ extern SEXP nano_ResultSymbol ;
53+ extern SEXP nano_SocketSymbol ;
54+ extern SEXP nano_StateSymbol ;
55+ extern SEXP nano_StreamSymbol ;
56+ extern SEXP nano_TextframesSymbol ;
57+ extern SEXP nano_UnserSymbol ;
58+ extern SEXP nano_UrlSymbol ;
5959
6060extern SEXP rnng_aio_call (SEXP );
6161extern SEXP rnng_aio_get_msg (SEXP , SEXP , SEXP );
You can’t perform that action at this time.
0 commit comments