Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-31077

do not attempt to save history to a blank filename

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Trivial - P5
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: Backlog
    • Component/s: Shell
    • Labels:
    • Case:

      Description

      As part of exit handling, the shell always calls shellHistoryDone(). However, there are some code paths that do not hit shellHistoryInit(); for such runs of the shell, the shell will output this message on exit:

      2017-09-13T10:30:28.490-0400 E -        [main] Error saving history file: FileOpenFailed: Unable to open() file : No such file or directory
      

      I can reproduce this by running the shell with this command and then pressing CTRL-C:

       ./mongo --nodb --eval "sleep(5000)" 
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              backlog-server-security Backlog - Security Team
              Reporter:
              milkie Eric Milkie
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated: