I got this issue because in startup.m,
I used a combination of the commands:
for the startup file to add itself to the path permanently.
When I was testing startup.m,
I used CTRL+Enter to 'evaluate selection' rather than 'run'.
Evaluate selection runs the code from a temporary location;
thus mfilename provides the temporary path to addpath,
which then gets then saved by savepath,
so during the next session you'll see the warning
about the temp path being in the path listings.