Removed unnecessary type cast.

This commit is contained in:
Roland Illig 2004-08-16 16:22:14 +00:00
parent 8aeea3256f
commit bfb2047463
3 changed files with 5 additions and 6 deletions

View File

@ -649,7 +649,7 @@ copy_file_file (FileOpContext *ctx, char *src_path, char *dst_path,
continue;
goto ret;
}
buf = (char *) g_malloc (buf_size);
buf = g_malloc (buf_size);
ctx->eta_secs = 0.0;
ctx->bps = 0;

View File

@ -400,7 +400,7 @@ init_subshell (void)
/* Initialise the pty's I/O buffer */
pty_buffer_size = INITIAL_PTY_BUFFER_SIZE;
pty_buffer = (char *) g_malloc (pty_buffer_size);
pty_buffer = g_malloc (pty_buffer_size);
/* Create a pipe for receiving the subshell's CWD */
@ -574,7 +574,7 @@ read_subshell_prompt (void)
FD_SET (subshell_pty, &tmp);
if (subshell_prompt == NULL) { /* First time through */
subshell_prompt = (char *) g_malloc (prompt_size);
subshell_prompt = g_malloc (prompt_size);
*subshell_prompt = '\0';
prompt_pos = 0;
}
@ -607,8 +607,7 @@ read_subshell_prompt (void)
subshell_prompt[prompt_pos++] = pty_buffer[i];
if (prompt_pos == prompt_size)
subshell_prompt =
(char *) g_realloc (subshell_prompt, prompt_size *=
2);
g_realloc (subshell_prompt, prompt_size *= 2);
}
subshell_prompt[prompt_pos] = '\0';

View File

@ -606,7 +606,7 @@ char *load_file (char *filename)
fclose (data_file);
return 0;
}
data = (char *) g_malloc (s.st_size+1);
data = g_malloc (s.st_size+1);
read_size = fread (data, 1, s.st_size, data_file);
data [read_size] = 0;
fclose (data_file);