NOTE - this just started happening in version 3.1.3.
Type "choose.files()" and in the ensuing dialog, select one file from whatever directory shows up, but make sure it is a file with a longer name than other files in that directory. Note the character string that is returned. Then, type "choose.files()" again, this time selecting a file with a shorter name than the one you chose first. Note that the returned character string is correct for whatever you selected.
Now repeat the above process, but this time type "choose.files(multi-FALSE)" each time, and again selecting a file with a longer name the first time, and a shorter name the second time. You will see that the second time, the character string is correct up to the end of the shorter file name, but then it contains additional characters left over from the first, longer file name". This is obviously the wrong characters to return.
Clearly, I can work around this by using the default for multi (which is TRUE), but I rather wanted to protect the user from mistakenly selecting more than one file in the application I am developing.
This should be fixed in R-devel and R-patched as of revision 68289.