Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4650036

Browse files
committed
Fix readlink() return value on Windows.
Ancient bug noticed while working on a test suite for these functions.Discussion:https://postgr.es/m/CA%2BhUKG%2BajSQ_8eu2AogTncOnZ5me2D-Cn66iN_-wZnRjLN%2Bicg%40mail.gmail.com
1 parent359d601 commit4650036

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

‎src/port/dirmod.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,9 @@ pgreadlink(const char *path, char *buf, size_t size)
359359
return-1;
360360
}
361361

362+
/* r includes the null terminator */
363+
r-=1;
364+
362365
/*
363366
* If the path starts with "\??\", which it will do in most (all?) cases,
364367
* strip those out.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp