mirror of
https://github.com/postgres/postgres.git
synced 2025-04-27 22:56:53 +03:00
Removed unsigned/signed mismatches.
This commit is contained in:
parent
11a497f99a
commit
14f29f640a
@ -1,4 +1,4 @@
|
|||||||
/* $PostgreSQL: pgsql/src/interfaces/ecpg/compatlib/informix.c,v 1.57 2009/01/15 11:52:54 petere Exp $ */
|
/* $PostgreSQL: pgsql/src/interfaces/ecpg/compatlib/informix.c,v 1.58 2009/05/20 16:49:23 meskes Exp $ */
|
||||||
|
|
||||||
#define POSTGRES_ECPG_INTERNAL
|
#define POSTGRES_ECPG_INTERNAL
|
||||||
#include "postgres_fe.h"
|
#include "postgres_fe.h"
|
||||||
@ -151,7 +151,7 @@ static char *
|
|||||||
ecpg_strndup(const char *str, size_t len)
|
ecpg_strndup(const char *str, size_t len)
|
||||||
{
|
{
|
||||||
int real_len = strlen(str);
|
int real_len = strlen(str);
|
||||||
int use_len = (real_len > len) ? len : real_len;
|
int use_len = (real_len > len) ? (int)len : real_len;
|
||||||
|
|
||||||
char *new = malloc(use_len + 1);
|
char *new = malloc(use_len + 1);
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/execute.c,v 1.83 2009/05/20 16:13:18 meskes Exp $ */
|
/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/execute.c,v 1.84 2009/05/20 16:49:23 meskes Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The aim is to get a simpler inteface to the database routines.
|
* The aim is to get a simpler inteface to the database routines.
|
||||||
@ -759,7 +759,7 @@ ecpg_store_input(const int lineno, const bool force_indicator, const struct vari
|
|||||||
case ECPGt_unsigned_char:
|
case ECPGt_unsigned_char:
|
||||||
{
|
{
|
||||||
/* set slen to string length if type is char * */
|
/* set slen to string length if type is char * */
|
||||||
int slen = (var->varcharsize == 0) ? strlen((char *) var->value) : var->varcharsize;
|
int slen = (var->varcharsize == 0) ? strlen((char *) var->value) : (unsigned int)var->varcharsize;
|
||||||
|
|
||||||
if (!(newcopy = ecpg_alloc(slen + 1, lineno)))
|
if (!(newcopy = ecpg_alloc(slen + 1, lineno)))
|
||||||
return false;
|
return false;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $PostgreSQL: pgsql/src/interfaces/ecpg/pgtypeslib/datetime.c,v 1.36 2009/05/20 16:13:18 meskes Exp $ */
|
/* $PostgreSQL: pgsql/src/interfaces/ecpg/pgtypeslib/datetime.c,v 1.37 2009/05/20 16:49:23 meskes Exp $ */
|
||||||
|
|
||||||
#include "postgres_fe.h"
|
#include "postgres_fe.h"
|
||||||
|
|
||||||
@ -347,7 +347,7 @@ PGTYPESdate_defmt_asc(date * d, char *fmt, char *str)
|
|||||||
char *fmt_ystart,
|
char *fmt_ystart,
|
||||||
*fmt_mstart,
|
*fmt_mstart,
|
||||||
*fmt_dstart;
|
*fmt_dstart;
|
||||||
int i;
|
unsigned int i;
|
||||||
int reading_digit;
|
int reading_digit;
|
||||||
int token_count;
|
int token_count;
|
||||||
char *str_copy;
|
char *str_copy;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $PostgreSQL: pgsql/src/interfaces/ecpg/pgtypeslib/dt_common.c,v 1.49 2009/05/20 16:13:18 meskes Exp $ */
|
/* $PostgreSQL: pgsql/src/interfaces/ecpg/pgtypeslib/dt_common.c,v 1.50 2009/05/20 16:49:23 meskes Exp $ */
|
||||||
|
|
||||||
#include "postgres_fe.h"
|
#include "postgres_fe.h"
|
||||||
|
|
||||||
@ -2583,7 +2583,7 @@ PGTYPEStimestamp_defmt_scan(char **str, char *fmt, timestamp * d,
|
|||||||
*pfmt,
|
*pfmt,
|
||||||
*tmp;
|
*tmp;
|
||||||
int err = 1;
|
int err = 1;
|
||||||
int j;
|
unsigned int j;
|
||||||
struct tm tm;
|
struct tm tm;
|
||||||
|
|
||||||
pfmt = fmt;
|
pfmt = fmt;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user