Don't touch upstream code unless you really have to. Fixing some whitespace in the upstream code is just not worth possible merge conflicts in the future.
That is, remove the following:
> -@@ -6027,8 +6539,13 @@ > +@@ -5908,8 +6407,7 @@ > + char buff[MAX_DATE_STRING_REP_LENGTH]; > + String str(buff, sizeof(buff), &my_charset_latin1); > + make_datetime((DATE_TIME_FORMAT *) 0, ltime, &str); > +- set_datetime_warning(MYSQL_ERROR::WARN_LEVEL_NOTE, > +- WARN_DATA_TRUNCATED, > ++ set_datetime_warning(MYSQL_ERROR::WARN_LEVEL_NOTE, WARN_DATA_TRUNCATED, > + str.ptr(), str.length(), MYSQL_TIMESTAMP_DATE, 1); > + error= 3; > + } > +@@ -6027,8 +6525,13 @@ > ** Stored as a 8 byte unsigned int. Should sometimes be change to a 6 byte int.
and this
> -@@ -7096,8 +7665,13 @@ > +@@ -6608,7 +7164,7 @@ > + String tmp(buf, sizeof(buf), cs); > + tmp.copy((char*) ptr, field_length, cs); > + push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN, > +- ER_TRUNCATED_WRONG_VALUE, > ++ ER_TRUNCATED_WRONG_VALUE, > + ER(ER_TRUNCATED_WRONG_VALUE), > + "DOUBLE", tmp.c_ptr()); > + } > +@@ -6626,7 +7182,7 @@ > + > + result= my_strntoll(cs, (char*) ptr,field_length,10,&end,&error); > + if (!table->in_use->no_errors && > +- (error || (field_length != (uint32)(end - (char*) ptr) && > ++ (error || (field_length != (uint32)(end - (char*) ptr) && > + !check_if_only_end_space(cs, end, > + (char*) ptr + field_length)))) > + { > +@@ -6634,7 +7190,7 @@ > + String tmp(buf, sizeof(buf), cs); > + tmp.copy((char*) ptr, field_length, cs); > + push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN, > +- ER_TRUNCATED_WRONG_VALUE, > ++ ER_TRUNCATED_WRONG_VALUE, > + ER(ER_TRUNCATED_WRONG_VALUE), > + "INTEGER", tmp.c_ptr()); > + } > +@@ -6673,7 +7229,7 @@ > + String tmp(buf, sizeof(buf), cs); > + tmp.copy((char*) ptr, field_length, cs); > + push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN, > +- ER_TRUNCATED_WRONG_VALUE, > ++ ER_TRUNCATED_WRONG_VALUE, > + ER(ER_TRUNCATED_WRONG_VALUE), > + "DECIMAL", tmp.c_ptr()); > + } > +@@ -7095,8 +7651,13 @@ > return 2;
> -@@ -8553,32 +9167,50 @@ > +@@ -8533,7 +9134,7 @@ > + > + /* Convert character set if necessary */ > + if (String::needs_conversion(length, cs, field_charset, ¬_used)) > +- { > ++ { > + uint dummy_errors; > + tmpstr.copy(from, length, cs, field_charset, &dummy_errors); > + from= tmpstr.ptr(); > +@@ -8552,32 +9153,50 @@ > tmp=(uint) my_strntoul(cs,from,length,10,&end,&err);
> - tmp=0; > +- tmp=0; > ++ tmp=0; > + if (truncated)
> +@@ -9097,15 +9736,20 @@ > + } > + > + > +-uint Field_bit::is_equal(Create_field *new_field) > ++uint Field_bit::is_equal(Create_field *new_field) > + { > + return (new_field->sql_type == real_type() && > + new_field->length == max_display_length()); > + } > + > +- > -int Field_bit::store(const char *from, uint length, CHARSET_INFO *cs)
« Back to merge proposal
Don't touch upstream code unless you really have to. Fixing some whitespace in the upstream code is just not worth possible merge conflicts in the future.
That is, remove the following:
> -@@ -6027,8 +6539,13 @@ DATE_STRING_ REP_LENGTH] ; latin1) ; (DATE_TIME_ FORMAT *) 0, ltime, &str); warning( MYSQL_ERROR: :WARN_LEVEL_ NOTE, TRUNCATED, warning( MYSQL_ERROR: :WARN_LEVEL_ NOTE, WARN_DATA_ TRUNCATED, _DATE, 1);
> +@@ -5908,8 +6407,7 @@
> + char buff[MAX_
> + String str(buff, sizeof(buff), &my_charset_
> + make_datetime(
> +- set_datetime_
> +- WARN_DATA_
> ++ set_datetime_
> + str.ptr(), str.length(), MYSQL_TIMESTAMP
> + error= 3;
> + }
> +@@ -6027,8 +6525,13 @@
> ** Stored as a 8 byte unsigned int. Should sometimes be change to a 6 byte int.
and this
> -@@ -7096,8 +7665,13 @@ printf( current_ thd, MYSQL_ERROR: :WARN_LEVEL_ WARN, WRONG_VALUE, WRONG_VALUE, _WRONG_ VALUE), length, 10,&end, &error) ; >in_use- >no_errors && if_only_ end_space( cs, end, printf( current_ thd, MYSQL_ERROR: :WARN_LEVEL_ WARN, WRONG_VALUE, WRONG_VALUE, _WRONG_ VALUE), printf( current_ thd, MYSQL_ERROR: :WARN_LEVEL_ WARN, WRONG_VALUE, WRONG_VALUE, _WRONG_ VALUE),
> +@@ -6608,7 +7164,7 @@
> + String tmp(buf, sizeof(buf), cs);
> + tmp.copy((char*) ptr, field_length, cs);
> + push_warning_
> +- ER_TRUNCATED_
> ++ ER_TRUNCATED_
> + ER(ER_TRUNCATED
> + "DOUBLE", tmp.c_ptr());
> + }
> +@@ -6626,7 +7182,7 @@
> +
> + result= my_strntoll(cs, (char*) ptr,field_
> + if (!table-
> +- (error || (field_length != (uint32)(end - (char*) ptr) &&
> ++ (error || (field_length != (uint32)(end - (char*) ptr) &&
> + !check_
> + (char*) ptr + field_length))))
> + {
> +@@ -6634,7 +7190,7 @@
> + String tmp(buf, sizeof(buf), cs);
> + tmp.copy((char*) ptr, field_length, cs);
> + push_warning_
> +- ER_TRUNCATED_
> ++ ER_TRUNCATED_
> + ER(ER_TRUNCATED
> + "INTEGER", tmp.c_ptr());
> + }
> +@@ -6673,7 +7229,7 @@
> + String tmp(buf, sizeof(buf), cs);
> + tmp.copy((char*) ptr, field_length, cs);
> + push_warning_
> +- ER_TRUNCATED_
> ++ ER_TRUNCATED_
> + ER(ER_TRUNCATED
> + "DECIMAL", tmp.c_ptr());
> + }
> +@@ -7095,8 +7651,13 @@
> return 2;
and this
> -@@ -8553,32 +9167,50 @@ :needs_ conversion( length, cs, field_charset, ¬_used)) cs,from, length, 10,&end, &err);
> +@@ -8533,7 +9134,7 @@
> +
> + /* Convert character set if necessary */
> + if (String:
> +- {
> ++ {
> + uint dummy_errors;
> + tmpstr.copy(from, length, cs, field_charset, &dummy_errors);
> + from= tmpstr.ptr();
> +@@ -8552,32 +9153,50 @@
> tmp=(uint) my_strntoul(
and this
> - tmp=0;
> +- tmp=0;
> ++ tmp=0;
> + if (truncated)
and this
> +@@ -9097,15 +9736,20 @@ :is_equal( Create_ field *new_field) :is_equal( Create_ field *new_field) >sql_type == real_type() && length( )); :store( const char *from, uint length, CHARSET_INFO *cs)
> + }
> +
> +
> +-uint Field_bit:
> ++uint Field_bit:
> + {
> + return (new_field-
> + new_field->length == max_display_
> + }
> +
> +-
> -int Field_bit: