54 |
cmd_file_handle (void) |
cmd_file_handle (void) |
55 |
{ |
{ |
56 |
char handle_name[LONG_NAME_LEN + 1]; |
char handle_name[LONG_NAME_LEN + 1]; |
57 |
|
enum file_handle_mode mode = MODE_TEXT; |
58 |
|
size_t length = 1024; |
59 |
|
size_t tab_width = 4; |
60 |
|
|
61 |
struct cmd_file_handle cmd; |
struct cmd_file_handle cmd; |
62 |
struct file_handle *handle; |
struct file_handle *handle; |
94 |
goto lossage; |
goto lossage; |
95 |
} |
} |
96 |
|
|
|
|
|
|
enum file_handle_mode mode = MODE_TEXT; |
|
|
size_t length = 1024; |
|
|
size_t tab_width = 4; |
|
|
|
|
|
|
|
97 |
switch (cmd.mode) |
switch (cmd.mode) |
98 |
{ |
{ |
99 |
case FH_CHARACTER: |
case FH_CHARACTER: |
128 |
handle = create_file_handle (handle_name, cmd.s_name, |
handle = create_file_handle (handle_name, cmd.s_name, |
129 |
mode, length, tab_width); |
mode, length, tab_width); |
130 |
|
|
131 |
|
free_file_handle (&cmd); |
132 |
return CMD_SUCCESS; |
return CMD_SUCCESS; |
133 |
|
|
134 |
lossage: |
lossage: |