mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-03 18:14:25 +03:00
* samba: Added some const qualifiers to reduce the number of gcc
warnings.
This commit is contained in:
parent
922043282d
commit
ee4987bb5d
@ -1,3 +1,8 @@
|
||||
2005-07-31 Roland Illig <roland.illig@gmx.de>
|
||||
|
||||
* samba: Added some const qualifiers to reduce the number of gcc
|
||||
warnings.
|
||||
|
||||
2005-07-25 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* extfs/urar.in: Remove month translation and year windowing -
|
||||
|
@ -50,7 +50,7 @@ int get_netmask(struct in_addr *ipaddr, struct in_addr *nmask);
|
||||
|
||||
/* The following definitions come from lib/slprintf.c */
|
||||
|
||||
int vslprintf(char *str, int n, char *format, va_list ap);
|
||||
int vslprintf(char *str, int n, const char *format, va_list ap);
|
||||
|
||||
/* The following definitions come from lib/system.c */
|
||||
|
||||
|
@ -74,7 +74,7 @@ int Debug1( char *, ... )
|
||||
__attribute__ ((format (printf, 1, 2)))
|
||||
#endif
|
||||
;
|
||||
BOOL dbgtext( char *, ... )
|
||||
BOOL dbgtext( const char *, ... )
|
||||
#ifdef __GNUC__
|
||||
__attribute__ ((format (printf, 1, 2)))
|
||||
#endif
|
||||
@ -865,12 +865,12 @@ typedef enum
|
||||
|
||||
struct enum_list {
|
||||
int value;
|
||||
char *name;
|
||||
const char *name;
|
||||
};
|
||||
|
||||
struct parm_struct
|
||||
{
|
||||
char *label;
|
||||
const char *label;
|
||||
parm_type type;
|
||||
parm_class class;
|
||||
void *ptr;
|
||||
@ -1341,7 +1341,7 @@ struct bitmap {
|
||||
#define ERRCMD 0xFF /* Command was not in the "SMB" format. */
|
||||
|
||||
#ifdef HAVE_STDARG_H
|
||||
int slprintf(char *str, int n, char *format, ...)
|
||||
int slprintf(char *str, int n, const char *format, ...)
|
||||
#ifdef __GNUC__
|
||||
__attribute__ ((format (printf, 3, 4)))
|
||||
#endif
|
||||
|
@ -347,7 +347,7 @@ BOOL dbghdr( int level, const char *file, const char *func, int line )
|
||||
* ************************************************************************** **
|
||||
*/
|
||||
#ifdef HAVE_STDARG_H
|
||||
BOOL dbgtext( char *format_str, ... )
|
||||
BOOL dbgtext( const char *format_str, ... )
|
||||
{
|
||||
va_list ap;
|
||||
pstring msgbuf;
|
||||
|
@ -27,7 +27,7 @@ extern int DEBUGLEVEL;
|
||||
/* this is like vsnprintf but the 'n' limit does not include
|
||||
the terminating null. So if you have a 1024 byte buffer then
|
||||
pass 1023 for n */
|
||||
int vslprintf(char *str, int n, char *format, va_list ap)
|
||||
int vslprintf(char *str, int n, const char *format, va_list ap)
|
||||
{
|
||||
int ret = vsnprintf(str, n, format, ap);
|
||||
if (ret > n || ret < 0) {
|
||||
@ -39,7 +39,7 @@ int vslprintf(char *str, int n, char *format, va_list ap)
|
||||
}
|
||||
|
||||
#ifdef HAVE_STDARG_H
|
||||
int slprintf(char *str, int n, char *format, ...)
|
||||
int slprintf(char *str, int n, const char *format, ...)
|
||||
{
|
||||
#else
|
||||
int slprintf(va_alist)
|
||||
|
@ -29,9 +29,9 @@ extern int DEBUGLEVEL;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
char *name;
|
||||
const char *name;
|
||||
int code;
|
||||
char *message;
|
||||
const char *message;
|
||||
} err_code_struct;
|
||||
|
||||
/* Dos Error Messages */
|
||||
@ -129,7 +129,7 @@ static err_code_struct const hard_msgs[] = {
|
||||
struct
|
||||
{
|
||||
int code;
|
||||
char *class;
|
||||
const char *class;
|
||||
err_code_struct const *err_msgs;
|
||||
} const err_classes [] = {
|
||||
{0,"SUCCESS",NULL},
|
||||
|
Loading…
Reference in New Issue
Block a user