~ubuntu-branches/ubuntu/utopic/vsftpd/utopic-proposed

« back to all changes in this revision

Viewing changes to ftpcmdio.c

  • Committer: Bazaar Package Importer
  • Author(s): Daniel Baumann
  • Date: 2009-05-03 17:49:00 UTC
  • mto: (2.4.1 sid) (1.5.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 15.
  • Revision ID: james.westby@ubuntu.com-20090503174900-0osuifgr8jknvu5e
Tags: upstream-2.1.1~pre1
ImportĀ upstreamĀ versionĀ 2.1.1~pre1

Show diffs side-by-side

added added

removed removed

Lines of Context:
83
83
   */
84
84
  vsf_sysutil_shutdown_read_failok(VSFTP_COMMAND_FD);
85
85
  ftp_write_text_common(p_sess, status, p_text, 1, ' ');
86
 
  vsf_sysutil_shutdown_failok(VSFTP_COMMAND_FD);
87
86
  vsf_sysutil_exit(0);
88
87
}
89
88
 
210
209
static void
211
210
control_getline(struct mystr* p_str, struct vsf_session* p_sess)
212
211
{
213
 
  int ret;
214
212
  if (p_sess->p_control_line_buf == 0)
215
213
  {
216
214
    vsf_secbuf_alloc(&p_sess->p_control_line_buf, VSFTP_MAX_COMMAND_LINE);
217
215
  }
218
 
  ret = ftp_getline(p_sess, p_str, p_sess->p_control_line_buf);
219
 
  if (ret < 0)
220
 
  {
221
 
    vsf_cmdio_write_exit(p_sess, FTP_BADCMD, "Input line too long.");
222
 
  }
 
216
  ftp_getline(p_sess, p_str, p_sess->p_control_line_buf);
223
217
  /* As mandated by the FTP specifications.. */
224
218
  str_replace_char(p_str, '\0', '\n');
225
219
  /* If the last character is a \r, strip it */