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

Commit9e12fb0

Browse files
committed
Remove some remaining traces of dsm_resize().
A couple of obsolete comments and unreachable blocks remained aftercommit3c60d0f.Discussion:https://postgr.es/m/CAA4eK1%2B%3DyAFUvpFoHXFi_gm8YqmXN-TtkFH%2BVYjvDLS6-SFq-Q%40mail.gmail.com
1 parentadd9182 commit9e12fb0

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

‎src/backend/storage/ipc/dsm_impl.c

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ dsm_impl_posix(dsm_op op, dsm_handle handle, Size request_size,
245245
}
246246

247247
/*
248-
* Create new segment or open an existing one for attach or resize.
248+
* Create new segment or open an existing one for attach.
249249
*
250250
* Even though we're not going through fd.c, we should be safe against
251251
* running out of file descriptors, because of NUM_RESERVED_FDS. We're
@@ -410,10 +410,6 @@ dsm_impl_sysv(dsm_op op, dsm_handle handle, Size request_size,
410410
charname[64];
411411
int*ident_cache;
412412

413-
/* Since resize isn't supported, reattach is a no-op. */
414-
if (op==DSM_OP_ATTACH&&*mapped_address!=NULL)
415-
return true;
416-
417413
/*
418414
* POSIX shared memory and mmap-based shared memory identify segments with
419415
* names. To avoid needless error message variation, we use the handle as
@@ -600,10 +596,6 @@ dsm_impl_windows(dsm_op op, dsm_handle handle, Size request_size,
600596
charname[64];
601597
MEMORY_BASIC_INFORMATIONinfo;
602598

603-
/* Since resize isn't supported, reattach is a no-op. */
604-
if (op==DSM_OP_ATTACH&&*mapped_address!=NULL)
605-
return true;
606-
607599
/*
608600
* Storing the shared memory segment in the Global\ namespace, can allow
609601
* any process running in any session to access that file mapping object
@@ -814,7 +806,7 @@ dsm_impl_mmap(dsm_op op, dsm_handle handle, Size request_size,
814806
return true;
815807
}
816808

817-
/* Create new segment or open an existing one for attach or resize. */
809+
/* Create new segment or open an existing one for attach. */
818810
flags=O_RDWR | (op==DSM_OP_CREATE ?O_CREAT |O_EXCL :0);
819811
if ((fd=OpenTransientFile(name,flags))==-1)
820812
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp