Why does craft.request.getQueryStringWithoutPath return an empty string? I'm trying to use craft.request.getQueryStringWithoutPath() to handle query strings on pagination, but for some reason it always seems to return an empty string. If I try craft.request.getQueryString() I get the query string as expected (eg. foo=bar), but with the exact same URL getQueryStringWithoutPath() gives me an empty string.

Am I doing something wrong? Could this be a server configuration issue (I'm using Apache 2.4 with a fairly default configuration)? Or could this be a Craft bug...? I'd be grateful for any help!
Turns out this was a bug that only occurred if the existing URL didn't have an URI associated with it.  i.e. http://craft.dev?foo=bar.

It's been fixed and will be included in the next 2.5 beta release (or the first 2.5 public release if you don't want to swap to the beta track).