### ImageMagick version

7.1.0-61 and above

### Operating system

Linux

### Operating system, version and so on

Linux

### Description

Now I've seen that rmagick 5.2.0 https://github.com/rmagick/rmagick/commit/b5abf2f64fab916e97c8be15309aff7135a1d768 test suite fails with 7.1.0-62 like:

```
Failures:

  1) Magick::Image::Info#origin works
     Failure/Error: expect(info.origin).to eq('+10+10')
     
       expected: "+10+10"
            got: "+10+10>"
     
       (compared using ==)
     # ./spec/rmagick/image/info/origin_spec.rb:6:in `block (2 levels) in <top (required)>'

Finished in 31.21 seconds (files took 0.83944 seconds to load)
739 examples, 1 failure, 1 pending
```
while with ImageMagick 7.1.0-57 this was okay.

https://github.com/rmagick/rmagick/blob/b5abf2f64fab916e97c8be15309aff7135a1d768/spec/rmagick/image/info/origin_spec.rb#L5-L6

Then looking at the code, basically the above test code is doing the below (written in C):

```
#include <stdio.h>
#include <stdlib.h>
#include <MagickCore/MagickCore.h>

#define MY_ASSERT(expr) \
	do { \
		if (!(expr)) { \
			fprintf(stderr, "LINE[%d]: assertion \"" #expr "\" failed.\n", __LINE__); \
			abort(); \
		} \
	} while(0)

int main(void){
	ImageInfo *iminfo = CloneImageInfo(NULL);

	const char *opt = "+10+10";
	{
		char *opt_info = opt_info = GetPageGeometry(opt);
		fprintf(stderr, "opt_info:[%s]\n", opt_info);

		if (IsGeometry(opt_info) == MagickFalse) {
			MY_ASSERT(0);
		}

		SetImageOption(iminfo, "origin", opt_info);
		RelinquishMagickMemory(opt_info);
	}

	{
		const char *val_info = GetImageOption(iminfo, "origin");
		fprintf(stderr, "val_info:[%s]\n", val_info);
	}

	DestroyImageInfo(iminfo);
}
```

Then with ImageMagick 7.1.0-57 the result was:
```
opt_info:[+10+10]
val_info:[+10+10]
```

On the other hand, with  ImageMagick 7.1.0-62 the result is:
```
opt_info:[+10+10>]
val_info:[+10+10>]
```

So looking at ImageMagick code, I definitely believe this is due to: https://github.com/ImageMagick/ImageMagick/commit/ae4f311e3468cfc23cfb92c5f38940b8d3240ea4#diff-664333386545044530e4a4bdb1088a93c5cee76177bff82064e1db7972b57347R157

With newly added this line:
https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/geometry.c#L157 , now in `GetPageGeometry`, for the case `Pagesizes[i] == MagickPagesize("", "") `, this `LocaleNCompare` will now always returns status 0:

https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/geometry.c#L490

.. because `Pagesizes[i].extent` is 0 (see: this definition: https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/geometry.c#L56 and `LocaleNCompare` definition:
https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/locale.c#L1534-L1535

)

So I guess perhaps the last  `Pagesizes` line for empty `name` should be removed, or iteration for `Pagesizes` in `GetPageGeometry` (and maybe in other function) should be modified (if the last one `Pagesizes` entry is meant to be sentinel).

### Steps to Reproduce

See above

### Images

_No response_
GetPageGeometry will always add '>' character since 7.1.0-61
This is a GitHub Issue
repo:ImageMagick
owner:ImageMagick
Title : GetPageGeometry will always add '>' character since 7.1.0-61
Issue date:

--- start body ---
### ImageMagick version

7.1.0-61 and above

### Operating system

Linux

### Operating system, version and so on

Linux

### Description

Now I've seen that rmagick 5.2.0 https://github.com/rmagick/rmagick/commit/b5abf2f64fab916e97c8be15309aff7135a1d768 test suite fails with 7.1.0-62 like:

```
Failures:

  1) Magick::Image::Info#origin works
     Failure/Error: expect(info.origin).to eq('+10+10')
     
       expected: "+10+10"
            got: "+10+10>"
     
       (compared using ==)
     # ./spec/rmagick/image/info/origin_spec.rb:6:in `block (2 levels) in <top (required)>'

Finished in 31.21 seconds (files took 0.83944 seconds to load)
739 examples, 1 failure, 1 pending
```
while with ImageMagick 7.1.0-57 this was okay.

https://github.com/rmagick/rmagick/blob/b5abf2f64fab916e97c8be15309aff7135a1d768/spec/rmagick/image/info/origin_spec.rb#L5-L6

Then looking at the code, basically the above test code is doing the below (written in C):

```
#include <stdio.h>
#include <stdlib.h>
#include <MagickCore/MagickCore.h>

#define MY_ASSERT(expr) \
	do { \
		if (!(expr)) { \
			fprintf(stderr, "LINE[%d]: assertion \"" #expr "\" failed.\n", __LINE__); \
			abort(); \
		} \
	} while(0)

int main(void){
	ImageInfo *iminfo = CloneImageInfo(NULL);

	const char *opt = "+10+10";
	{
		char *opt_info = opt_info = GetPageGeometry(opt);
		fprintf(stderr, "opt_info:[%s]\n", opt_info);

		if (IsGeometry(opt_info) == MagickFalse) {
			MY_ASSERT(0);
		}

		SetImageOption(iminfo, "origin", opt_info);
		RelinquishMagickMemory(opt_info);
	}

	{
		const char *val_info = GetImageOption(iminfo, "origin");
		fprintf(stderr, "val_info:[%s]\n", val_info);
	}

	DestroyImageInfo(iminfo);
}
```

Then with ImageMagick 7.1.0-57 the result was:
```
opt_info:[+10+10]
val_info:[+10+10]
```

On the other hand, with  ImageMagick 7.1.0-62 the result is:
```
opt_info:[+10+10>]
val_info:[+10+10>]
```

So looking at ImageMagick code, I definitely believe this is due to: https://github.com/ImageMagick/ImageMagick/commit/ae4f311e3468cfc23cfb92c5f38940b8d3240ea4#diff-664333386545044530e4a4bdb1088a93c5cee76177bff82064e1db7972b57347R157

With newly added this line:
https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/geometry.c#L157 , now in `GetPageGeometry`, for the case `Pagesizes[i] == MagickPagesize("", "") `, this `LocaleNCompare` will now always returns status 0:

https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/geometry.c#L490

.. because `Pagesizes[i].extent` is 0 (see: this definition: https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/geometry.c#L56 and `LocaleNCompare` definition:
https://github.com/ImageMagick/ImageMagick/blob/3c6702293ed035fb8bb2a6491068a6b2b121c84e/MagickCore/locale.c#L1534-L1535

)

So I guess perhaps the last  `Pagesizes` line for empty `name` should be removed, or iteration for `Pagesizes` in `GetPageGeometry` (and maybe in other function) should be modified (if the last one `Pagesizes` entry is meant to be sentinel).

### Steps to Reproduce

See above

### Images

_No response_
--- end body ---
