mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 02:42:49 -04:00
a few more warning squelches
This commit is contained in:
parent
9b952e3922
commit
923c9929a1
@ -1202,7 +1202,7 @@ read_tar(TarDef &tar, istream &stream) {
|
|||||||
stream.seekg(0, ios::beg);
|
stream.seekg(0, ios::beg);
|
||||||
nassertr(_tar_istream == NULL, false);
|
nassertr(_tar_istream == NULL, false);
|
||||||
_tar_istream = &stream;
|
_tar_istream = &stream;
|
||||||
if (tar_open(&tfile, "dummy", &tt, O_RDONLY, 0, 0) != 0) {
|
if (tar_open(&tfile, (char *)"dummy", &tt, O_RDONLY, 0, 0) != 0) {
|
||||||
_tar_istream = NULL;
|
_tar_istream = NULL;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -90,7 +90,7 @@ open_read(istream *source, bool owns_source) {
|
|||||||
_z_source.zfree = (free_func)&do_zlib_free;
|
_z_source.zfree = (free_func)&do_zlib_free;
|
||||||
#endif
|
#endif
|
||||||
_z_source.opaque = Z_NULL;
|
_z_source.opaque = Z_NULL;
|
||||||
_z_source.msg = "no error message";
|
_z_source.msg = (char *)"no error message";
|
||||||
|
|
||||||
int result = inflateInit(&_z_source);
|
int result = inflateInit(&_z_source);
|
||||||
if (result < 0) {
|
if (result < 0) {
|
||||||
@ -141,7 +141,7 @@ open_write(ostream *dest, bool owns_dest, int compression_level) {
|
|||||||
_z_dest.zfree = (free_func)&do_zlib_free;
|
_z_dest.zfree = (free_func)&do_zlib_free;
|
||||||
#endif
|
#endif
|
||||||
_z_dest.opaque = Z_NULL;
|
_z_dest.opaque = Z_NULL;
|
||||||
_z_dest.msg = "no error message";
|
_z_dest.msg = (char *)"no error message";
|
||||||
|
|
||||||
int result = deflateInit(&_z_dest, compression_level);
|
int result = deflateInit(&_z_dest, compression_level);
|
||||||
if (result < 0) {
|
if (result < 0) {
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
TypeHandle StencilAttrib::_type_handle;
|
TypeHandle StencilAttrib::_type_handle;
|
||||||
int StencilAttrib::_attrib_slot;
|
int StencilAttrib::_attrib_slot;
|
||||||
|
|
||||||
char *StencilAttrib::
|
const char *StencilAttrib::
|
||||||
stencil_render_state_name_array [StencilAttrib::SRS_total] =
|
stencil_render_state_name_array [StencilAttrib::SRS_total] =
|
||||||
{
|
{
|
||||||
"SRS_front_enable",
|
"SRS_front_enable",
|
||||||
|
@ -153,7 +153,7 @@ PUBLISHED:
|
|||||||
INLINE unsigned int get_render_state (unsigned int render_state_identifier) const;
|
INLINE unsigned int get_render_state (unsigned int render_state_identifier) const;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static char *stencil_render_state_name_array [SRS_total];
|
static const char *stencil_render_state_name_array [SRS_total];
|
||||||
|
|
||||||
virtual void output(ostream &out) const;
|
virtual void output(ostream &out) const;
|
||||||
|
|
||||||
|
@ -46,7 +46,7 @@ struct bitstream
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
EXPCL_PANDA_PNMIMAGE struct bitstream *
|
EXPCL_PANDA_PNMIMAGE struct bitstream *
|
||||||
pm_bitinit(istream *f, char *mode)
|
pm_bitinit(istream *f, const char *mode)
|
||||||
{
|
{
|
||||||
struct bitstream *ans = (struct bitstream *)0;
|
struct bitstream *ans = (struct bitstream *)0;
|
||||||
|
|
||||||
@ -66,7 +66,7 @@ pm_bitinit(istream *f, char *mode)
|
|||||||
}
|
}
|
||||||
|
|
||||||
EXPCL_PANDA_PNMIMAGE struct bitstream *
|
EXPCL_PANDA_PNMIMAGE struct bitstream *
|
||||||
pm_bitinit(ostream *f, char *mode)
|
pm_bitinit(ostream *f, const char *mode)
|
||||||
{
|
{
|
||||||
struct bitstream *ans = (struct bitstream *)0;
|
struct bitstream *ans = (struct bitstream *)0;
|
||||||
|
|
||||||
|
@ -30,8 +30,8 @@ typedef struct bitstream *BITSTREAM;
|
|||||||
* Returns 0 on error.
|
* Returns 0 on error.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern EXPCL_PANDA_PNMIMAGE BITSTREAM pm_bitinit(istream *f, char *mode);
|
extern EXPCL_PANDA_PNMIMAGE BITSTREAM pm_bitinit(istream *f, const char *mode);
|
||||||
extern EXPCL_PANDA_PNMIMAGE BITSTREAM pm_bitinit(ostream *f, char *mode);
|
extern EXPCL_PANDA_PNMIMAGE BITSTREAM pm_bitinit(ostream *f, const char *mode);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* pm_bitfini() - deallocate the given BITSTREAM.
|
* pm_bitfini() - deallocate the given BITSTREAM.
|
||||||
|
@ -55,7 +55,7 @@ static short get_byte_as_short (istream *f);
|
|||||||
static int readerr (istream *f);
|
static int readerr (istream *f);
|
||||||
static void * xmalloc (int bytes);
|
static void * xmalloc (int bytes);
|
||||||
#define MALLOC(n, type) (type *)xmalloc((n) * sizeof(type))
|
#define MALLOC(n, type) (type *)xmalloc((n) * sizeof(type))
|
||||||
static char * compression_name (char compr);
|
static const char * compression_name (char compr);
|
||||||
static void read_bytes (istream *ifp, int n, char *buf);
|
static void read_bytes (istream *ifp, int n, char *buf);
|
||||||
static bool read_header(istream *ifp, Header *head, const string &magic_number);
|
static bool read_header(istream *ifp, Header *head, const string &magic_number);
|
||||||
static TabEntry * read_table (istream *ifp, int tablen);
|
static TabEntry * read_table (istream *ifp, int tablen);
|
||||||
@ -503,7 +503,7 @@ xmalloc(int bytes) {
|
|||||||
return mem;
|
return mem;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char *
|
static const char *
|
||||||
compression_name(char compr) {
|
compression_name(char compr) {
|
||||||
switch( compr ) {
|
switch( compr ) {
|
||||||
case STORAGE_VERBATIM:
|
case STORAGE_VERBATIM:
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include "zgl.h"
|
#include "zgl.h"
|
||||||
|
|
||||||
void gl_fatal_error(char *format, ...)
|
void gl_fatal_error(const char *format, ...)
|
||||||
{
|
{
|
||||||
va_list ap;
|
va_list ap;
|
||||||
|
|
||||||
|
@ -916,7 +916,7 @@ set_wm_properties(const WindowProperties &properties, bool already_mapped) {
|
|||||||
XClassHint *class_hints_p = NULL;
|
XClassHint *class_hints_p = NULL;
|
||||||
if (properties.get_undecorated()) {
|
if (properties.get_undecorated()) {
|
||||||
class_hints_p = XAllocClassHint();
|
class_hints_p = XAllocClassHint();
|
||||||
class_hints_p->res_class = "Undecorated";
|
class_hints_p->res_class = (char *)"Undecorated";
|
||||||
|
|
||||||
if (!properties.get_fullscreen()) {
|
if (!properties.get_fullscreen()) {
|
||||||
type_data[next_type_data++] = _net_wm_window_type_splash;
|
type_data[next_type_data++] = _net_wm_window_type_splash;
|
||||||
|
@ -230,7 +230,7 @@ void gl_resizeImageNoInterpolate(unsigned char *dest,int xsize_dest,int ysize_de
|
|||||||
|
|
||||||
GLContext *gl_get_context(void);
|
GLContext *gl_get_context(void);
|
||||||
|
|
||||||
void gl_fatal_error(char *format, ...);
|
void gl_fatal_error(const char *format, ...);
|
||||||
|
|
||||||
|
|
||||||
/* specular buffer "api" */
|
/* specular buffer "api" */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user