const char * correctness fixes (in C code)
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13939 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
c7df90e675
commit
dac89e16d4
7 changed files with 10 additions and 10 deletions
|
|
@ -254,7 +254,7 @@ extern int DohDelmeta(DOH *, const DOH *);
|
|||
|
||||
/* Utility functions */
|
||||
|
||||
extern void DohEncoding(char *name, DOH *(*fn) (DOH *s));
|
||||
extern void DohEncoding(const char *name, DOH *(*fn) (DOH *s));
|
||||
extern int DohPrintf(DOHFile * obj, const char *format, ...);
|
||||
extern int DohvPrintf(DOHFile * obj, const char *format, va_list ap);
|
||||
extern int DohPrintv(DOHFile * obj, ...);
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ typedef struct {
|
|||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
typedef struct DohObjInfo {
|
||||
char *objname; /* Object name */
|
||||
const char *objname; /* Object name */
|
||||
|
||||
/* Basic object methods */
|
||||
void (*doh_del) (DOH *obj); /* Delete object */
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ static int Writen(DOH *out, void *buffer, int len) {
|
|||
* two file-like objects and operate as a filter.
|
||||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
void DohEncoding(char *name, DOH *(*fn) (DOH *s)) {
|
||||
void DohEncoding(const char *name, DOH *(*fn) (DOH *s)) {
|
||||
if (!encodings)
|
||||
encodings = NewHash();
|
||||
Setattr(encodings, (void *) name, NewVoid((void *) fn, 0));
|
||||
|
|
@ -102,7 +102,7 @@ static DOH *encode(char *name, DOH *s) {
|
|||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
int DohvPrintf(DOH *so, const char *format, va_list ap) {
|
||||
static char *fmt_codes = "dioxXucsSfeEgGpn";
|
||||
static const char *fmt_codes = "dioxXucsSfeEgGpn";
|
||||
int state = 0;
|
||||
const char *p = format;
|
||||
char newformat[256];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue