Merge pull request #212 from jugglerchris/master

Allow sorting maildir list in Lua.
Fix a crash with prompt strings containing '%'.

Replace a couple of 'printw(str)' with 'printw("%s", str)'.  I otherwise
got a crash on eg prompt_chars("blah%n", "abc"):

  ** %n in writable segment detected ***

  Program received signal SIGABRT, Aborted.