diff --git a/hwpfilter/source/formula.h b/hwpfilter/source/formula.h index d0d4f9805c4e..ebdb1acc3b84 100644 --- a/hwpfilter/source/formula.h +++ b/hwpfilter/source/formula.h @@ -53,7 +53,7 @@ public: void setAttributeListImpl( AttributeListImpl *p ) { pList = p; - rList = (XAttributeList *) pList; + rList = static_cast(pList); } int parse(); private: diff --git a/hwpfilter/source/hgzip.cxx b/hwpfilter/source/hgzip.cxx index baf3b20e43f5..915ea3135af7 100644 --- a/hwpfilter/source/hgzip.cxx +++ b/hwpfilter/source/hgzip.cxx @@ -61,9 +61,9 @@ gz_stream *gz_open(HStream & _stream) s = static_cast(ALLOC(sizeof(gz_stream))); if (!s) return Z_NULL; - s->stream.zalloc = (alloc_func) 0; - s->stream.zfree = (free_func) 0; - s->stream.opaque = (voidpf) 0; + s->stream.zalloc = nullptr; + s->stream.zfree = nullptr; + s->stream.opaque = nullptr; s->stream.next_in = s->inbuf = Z_NULL; s->stream.next_out = s->outbuf = Z_NULL; s->stream.avail_in = s->stream.avail_out = 0; diff --git a/hwpfilter/source/hwpreader.cxx b/hwpfilter/source/hwpreader.cxx index bcdf9d154640..a68a29b294b4 100644 --- a/hwpfilter/source/hwpreader.cxx +++ b/hwpfilter/source/hwpreader.cxx @@ -112,7 +112,7 @@ struct HwpReaderPrivate HwpReader::HwpReader() { pList = new AttributeListImpl; - rList = (XAttributeList *) pList; + rList = static_cast(pList); d = new HwpReaderPrivate; } diff --git a/hwpfilter/source/hwpreader.hxx b/hwpfilter/source/hwpreader.hxx index bb4e0d283101..15baadd89f09 100644 --- a/hwpfilter/source/hwpreader.hxx +++ b/hwpfilter/source/hwpreader.hxx @@ -189,7 +189,7 @@ Reference< XInterface > HwpImportFilter_CreateInstance( { HwpImportFilter *p = new HwpImportFilter( rSMgr ); - return Reference< XInterface > ( (OWeakObject* )p ); + return Reference< XInterface > ( static_cast(p) ); } Sequence< OUString > HwpImportFilter::getSupportedServiceNames_Static() throw () diff --git a/hwpfilter/source/lexer.cxx b/hwpfilter/source/lexer.cxx index 9c7cea8820b7..341bebb31aa2 100644 --- a/hwpfilter/source/lexer.cxx +++ b/hwpfilter/source/lexer.cxx @@ -203,7 +203,7 @@ static int yy_n_chars; /* number of characters read into yy_ch_buf */ int yyleng; /* Points to current character in buffer. */ -static char *yy_c_buf_p = (char *) 0; +static char *yy_c_buf_p = nullptr; static int yy_init = 1; /* whether we need to initialize */ static int yy_start = 0; /* start state number */ @@ -230,7 +230,7 @@ static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t )); static void yy_flex_free YY_PROTO(( void * )); typedef unsigned char YY_CHAR; -FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0; +FILE *yyin = nullptr, *yyout = nullptr; typedef int yy_state_type; extern char *yytext; #define yytext_ptr yytext @@ -1590,7 +1590,7 @@ static int yy_get_next_buffer() b->yy_ch_buf = static_cast( /* Include room in for 2 EOB chars. */ - yy_flex_realloc( (void *) b->yy_ch_buf, + yy_flex_realloc( static_cast(b->yy_ch_buf), b->yy_buf_size + 2 )); } else @@ -1811,12 +1811,12 @@ YY_BUFFER_STATE b; return; if ( b == yy_current_buffer ) - yy_current_buffer = (YY_BUFFER_STATE) 0; + yy_current_buffer = nullptr; if ( b->yy_is_our_buffer ) - yy_flex_free( (void *) b->yy_ch_buf ); + yy_flex_free( static_cast(b->yy_ch_buf) ); - yy_flex_free( (void *) b ); + yy_flex_free( static_cast(b) ); }