Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Issue 272039: Add FilePathTest.StripTrailingSeparator to base_unittests to test FilePath::StripTrailingSeparator (Closed)

Created:
11 years, 2 months ago by Mark Mentovai
Modified:
9 years, 7 months ago
CC:
chromium-reviews_googlegroups.com, brettw+cc_chromium.org, tim (not reviewing), Paweł Hajdan Jr.
Visibility:
Public.

Description

Add FilePathTest.StripTrailingSeparators to base_unittests to test FilePath::StripTrailingSeparators. BUG=24692 TEST=this Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=28832

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Patch Set 4 : '' #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+64 lines, -0 lines) Patch
M base/file_path_unittest.cc View 1 2 3 1 chunk +64 lines, -0 lines 2 comments Download

Messages

Total messages: 5 (0 generated)
Mark Mentovai
http://codereview.chromium.org/272039 I don't have a Windows machine handy to test it on, so we'll see ...
11 years, 2 months ago (2009-10-13 03:40:07 UTC) #1
Mark Mentovai
11 years, 2 months ago (2009-10-13 04:10:36 UTC) #2
Erik does not do reviews
LGTM http://codereview.chromium.org/272039/diff/4002/5002 File base/file_path_unittest.cc (right): http://codereview.chromium.org/272039/diff/4002/5002#newcode319 Line 319: { FPL("//"), FPL("//") }, is this use ...
11 years, 2 months ago (2009-10-13 16:57:01 UTC) #3
Mark Mentovai
Erik Kay wrote: > http://codereview.chromium.org/272039/diff/4002/5002 > File base/file_path_unittest.cc (right): > > http://codereview.chromium.org/272039/diff/4002/5002#newcode319 > Line 319: ...
11 years, 2 months ago (2009-10-13 17:25:47 UTC) #4
Erik does not do reviews
11 years, 2 months ago (2009-10-13 17:30:45 UTC) #5
Neat.  Thanks for the info.  I was confident that these meant
something... I just didn't know what.

Erik


On Tue, Oct 13, 2009 at 10:25 AM,  <mark@chromium.org> wrote:
> Erik Kay wrote:
>>
>> http://codereview.chromium.org/272039/diff/4002/5002
>> File base/file_path_unittest.cc (right):
>
>> http://codereview.chromium.org/272039/diff/4002/5002#newcode319
>> Line 319: { FPL("//"), =A0 =A0 =A0 =A0 =A0 =A0FPL("//") },
>> is this use case for windows network paths using / instead of \?
>
> That's one use.
>
> Little-known fact: a double leading slash is actually part of the POSIX
> standard. =A0The system is allowed to treat // as an alternate root. =A0M=
ost
> don't,
> but in case we ever come across a system that works this way, we need to
> handle
> it properly.
>
> See the top of file_path.h (where I wrote "Surprise!"),
> http://www.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#ta=
g_03_266,
> and
> http://www.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap04.html#ta=
g_04_12
> .
>
> http://codereview.chromium.org/272039/diff/4002/5002#newcode334
>>
>> Line 334: { FPL("c://"), =A0 =A0 =A0 =A0 =A0FPL("c://") },
>> just curious, what is this use case for?
>
> Windows treats c:\\ the same way it treats \\. =A0This was intended to al=
low
> older
> applications that require drive letters to support \\server\share\path, b=
y
> permitting c:\\server\share\path as an equivalent. =A0Since the OS treats
> these
> paths specially, we need to do the same. =A0Since Windows can use either =
/ or
> \ as
> the separator, we treat c://, c:\\, //, and \\ all equivalently.
>
> http://codereview.chromium.org/272039
>

Powered by Google App Engine
This is Rietveld 408576698