Commit 6b5d02ac authored by unknown's avatar unknown

Merge work:/home/bk/mysql-4.0

into mysql.sashanet.com:/home/sasha/src/bk/mysql-4.0

parents 20763b0d 57546cb7
...@@ -46,6 +46,35 @@ const char *client_errors[]= ...@@ -46,6 +46,35 @@ const char *client_errors[]=
"Kann den Status der Named Pipe nicht setzen. Host: %-.64s pipe: %-.32s (%lu)", "Kann den Status der Named Pipe nicht setzen. Host: %-.64s pipe: %-.32s (%lu)",
"Can't initialize character set %-.64s (path: %-.64s)", "Can't initialize character set %-.64s (path: %-.64s)",
"Got packet bigger than 'max_allowed_packet'", "Got packet bigger than 'max_allowed_packet'",
"Embedded server"
};
/* Start of code added by Roberto M. Serqueira - martinsc@uol.com.br - 05.24.2001 */
#elif defined PORTUGUESE
const char *client_errors[]=
{
"Erro desconhecido do MySQL",
"No pode criar 'UNIX socket' (%d)",
"No pode se conectar ao servidor MySQL local atravs do 'socket' '%-.64s' (%d)",
"No pode se conectar ao servidor MySQL em '%-.64s' (%d)",
"No pode criar 'socket TCP/IP' (%d)",
"'Host' servidor MySQL '%-.64s' (%d) desconhecido",
"Servidor MySQL desapareceu",
"Incompatibilidade de protocolos. Verso do Servidor: %d - Verso do Cliente: %d",
"Cliente do MySQL com falta de memria",
"Informao invlida de 'host'",
"Localhost via 'UNIX socket'",
"%-.64s via 'TCP/IP'",
"Erro na negociao de acesso ao servidor",
"Conexo perdida com servidor MySQL durante 'query'",
"Comandos fora de sincronismo. Voc no pode executar este comando agora",
"%-.64s via 'named pipe'",
"No pode esperar pelo 'named pipe' para o 'host' %-.64s - 'pipe' %-.32s (%lu)",
"No pode abrir 'named pipe' para o 'host' %-.64s - 'pipe' %-.32s (%lu)",
"No pode estabelecer o estado do 'named pipe' para o 'host' %-.64s - 'pipe' %-.32s (%lu)",
"No pode inicializar conjunto de caracteres %-.64s (caminho %-.64s)",
"Obteve pacote maior do que 'max_allowed_packet'",
"Embedded server", "Embedded server",
}; };
...@@ -73,7 +102,7 @@ const char *client_errors[]= ...@@ -73,7 +102,7 @@ const char *client_errors[]=
"Can't set state of named pipe to host: %-.64s pipe: %-.32s (%lu)", "Can't set state of named pipe to host: %-.64s pipe: %-.32s (%lu)",
"Can't initialize character set %-.64s (path: %-.64s)", "Can't initialize character set %-.64s (path: %-.64s)",
"Got packet bigger than 'max_allowed_packet'", "Got packet bigger than 'max_allowed_packet'",
"Embedded server", "Embedded server"
}; };
#endif #endif
......
...@@ -87,13 +87,13 @@ int my_delete_with_symlink(const char *name, myf MyFlags) ...@@ -87,13 +87,13 @@ int my_delete_with_symlink(const char *name, myf MyFlags)
int my_rename_with_symlink(const char *from, const char *to, myf MyFlags) int my_rename_with_symlink(const char *from, const char *to, myf MyFlags)
{ {
#ifdef HAVE_READLINK #ifndef HAVE_READLINK
return my_rename(from, to, MyFlags); return my_rename(from, to, MyFlags);
#else #else
char link_name[FN_REFLEN], tmp_name[FN_REFLEN]; char link_name[FN_REFLEN], tmp_name[FN_REFLEN];
int was_symlink= (!my_disable_symlinks && int was_symlink= (!my_disable_symlinks &&
!my_readlink(link_name, name, MYF(0))); !my_readlink(link_name, from, MYF(0)));
int result; int result=0;
DBUG_ENTER("my_rename_with_symlink"); DBUG_ENTER("my_rename_with_symlink");
if (!was_symlink) if (!was_symlink)
...@@ -105,7 +105,7 @@ int my_rename_with_symlink(const char *from, const char *to, myf MyFlags) ...@@ -105,7 +105,7 @@ int my_rename_with_symlink(const char *from, const char *to, myf MyFlags)
/* Create new symlink */ /* Create new symlink */
if (my_symlink(tmp_name, to, MyFlags)) if (my_symlink(tmp_name, to, MyFlags))
DBUG_RETURN(-1); DBUG_RETURN(1);
/* /*
Rename symlinked file if the base name didn't change. Rename symlinked file if the base name didn't change.
...@@ -115,18 +115,23 @@ int my_rename_with_symlink(const char *from, const char *to, myf MyFlags) ...@@ -115,18 +115,23 @@ int my_rename_with_symlink(const char *from, const char *to, myf MyFlags)
if (strcmp(link_name, tmp_name) && my_rename(link_name, tmp_name, MyFlags)) if (strcmp(link_name, tmp_name) && my_rename(link_name, tmp_name, MyFlags))
{ {
int save_errno=my_errno;
my_delete(to, MyFlags); /* Remove created symlink */ my_delete(to, MyFlags); /* Remove created symlink */
DBUG_RETURN(-1); my_errno=save_errno;
DBUG_RETURN(1);
} }
/* Remove original symlink */ /* Remove original symlink */
if (my_delete(from, MyFlags)) if (my_delete(from, MyFlags))
{ {
int save_errno=my_errno;
/* Remove created link */ /* Remove created link */
my_delete(to, MyFlags); my_delete(to, MyFlags);
/* Rename file back */ /* Rename file back */
if (strcmp(link_name, tmp_name)) if (strcmp(link_name, tmp_name))
(void) my_rename(tmp_name, link_name, MyFlags); (void) my_rename(tmp_name, link_name, MyFlags);
my_errno=save_errno;
result= 1;
} }
DBUG_RETURN(result); DBUG_RETURN(result);
#endif /* HAVE_READLINK */ #endif /* HAVE_READLINK */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment