core,w32: Fix missing sentinel in dir name builder.