mirror of https://github.com/acanas/swad-core.git
Version 15.207.1
This commit is contained in:
parent
fd8caa4bfe
commit
9cb8367ea5
|
@ -136,14 +136,15 @@
|
|||
/****************************** Public constants *****************************/
|
||||
/*****************************************************************************/
|
||||
|
||||
#define Log_PLATFORM_VERSION "SWAD 15.207 (2016-05-01)"
|
||||
#define Log_PLATFORM_VERSION "SWAD 15.207.1 (2016-05-01)"
|
||||
#define CSS_FILE "swad15.204.1.css"
|
||||
#define JS_FILE "swad15.197.js"
|
||||
|
||||
// Number of lines (includes comments but not blank lines) has been got with the following command:
|
||||
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
|
||||
/*
|
||||
Version 15.207: May 01, 2016 Add default values for fields in users' data table. (201424 lines)
|
||||
Version 15.207.1: May 01, 2016 Minor fix to avoid warning related to char type limits. (201515 lines)
|
||||
Version 15.207: May 01, 2016 Add default values for fields in users' data table. (201514 lines)
|
||||
Birthday default value now is NULL.
|
||||
18 changes necessary in database:
|
||||
ALTER TABLE usr_data CHANGE COLUMN EncryptedUsrCod EncryptedUsrCod CHAR(43) NOT NULL DEFAULT '';
|
||||
|
|
|
@ -51,7 +51,7 @@ extern struct Globals Gbl; // Declaration in swad.c
|
|||
/*************************** Internal prototypes *****************************/
|
||||
/*****************************************************************************/
|
||||
|
||||
static unsigned Str_GetNextASCIICharFromStr (const char *Ptr,char *Ch);
|
||||
static unsigned Str_GetNextASCIICharFromStr (const char *Ptr,unsigned char *Ch);
|
||||
static int Str_ReadCharAndSkipComments (FILE *FileSrc,Str_SkipHTMLComments_t SkipHTMLComments);
|
||||
static int Str_ReadCharAndSkipCommentsWriting (FILE *FileSrc,FILE *FileTgt,Str_SkipHTMLComments_t SkipHTMLComments);
|
||||
static int Str_ReadCharAndSkipCommentsBackward (FILE *FileSrc,Str_SkipHTMLComments_t SkipHTMLComments);
|
||||
|
@ -150,7 +150,7 @@ void Str_InsertLinks (char *Txt,unsigned long MaxLength,size_t MaxCharsURLOnScre
|
|||
size_t NumBytesToCopy;
|
||||
size_t NumBytesToShow; // Length of the link displayed on screen (may be shorter than actual length)
|
||||
char LimitedURL[MAX_BYTES_LIMITED_URL+1];
|
||||
char Ch;
|
||||
unsigned char Ch;
|
||||
|
||||
/****** Initialize constant anchors and their lengths *****/
|
||||
TxtLength = strlen (Txt);
|
||||
|
@ -212,7 +212,7 @@ void Str_InsertLinks (char *Txt,unsigned long MaxLength,size_t MaxCharsURLOnScre
|
|||
{
|
||||
NumChars1 = Str_GetNextASCIICharFromStr (PtrSrc,&Ch);
|
||||
PtrSrc += NumChars1;
|
||||
if ((Ch >= 0 && Ch <= 32) || Ch == '<' || Ch == '"')
|
||||
if (Ch <= 32 || Ch == '<' || Ch == '"')
|
||||
{
|
||||
Links[NumLinks].PtrEnd = PtrSrc - NumChars1 - 1;
|
||||
break;
|
||||
|
@ -221,7 +221,7 @@ void Str_InsertLinks (char *Txt,unsigned long MaxLength,size_t MaxCharsURLOnScre
|
|||
{
|
||||
NumChars2 = Str_GetNextASCIICharFromStr (PtrSrc,&Ch);
|
||||
PtrSrc += NumChars2;
|
||||
if ((Ch >= 0 && Ch <= 32) || Ch == '<' || Ch == '"')
|
||||
if (Ch <= 32 || Ch == '<' || Ch == '"')
|
||||
{
|
||||
Links[NumLinks].PtrEnd = PtrSrc - NumChars2 - NumChars1 - 1;
|
||||
break;
|
||||
|
@ -480,7 +480,7 @@ void Str_InsertLinks (char *Txt,unsigned long MaxLength,size_t MaxCharsURLOnScre
|
|||
/*****************************************************************************/
|
||||
// Returns number of char analyzed
|
||||
|
||||
static unsigned Str_GetNextASCIICharFromStr (const char *Ptr,char *Ch)
|
||||
static unsigned Str_GetNextASCIICharFromStr (const char *Ptr,unsigned char *Ch)
|
||||
{
|
||||
unsigned NumChars;
|
||||
unsigned Num;
|
||||
|
@ -544,19 +544,19 @@ static unsigned Str_GetNextASCIICharFromStr (const char *Ptr,char *Ch)
|
|||
}
|
||||
else
|
||||
{
|
||||
*Ch = *Ptr;
|
||||
*Ch = (unsigned char) *Ptr;
|
||||
return NumChars;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
*Ch = *Ptr;
|
||||
*Ch = (unsigned char) *Ptr;
|
||||
return 2;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
*Ch = *Ptr;
|
||||
*Ch = (unsigned char) *Ptr;
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue