# Small PHPAPI addition

- Thread: https://externals.io/message/53560
- Original archive: https://news-web.php.net/php.internals/53560
- Started by Derick Rethans on 2011-06-23T20:47:21+00:00
- Messages: 7
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #53560 — Derick Rethans — 2011-06-23T20:47:21+00:00

URL: https://externals.io/message/53560#53560

Hi!

In order to fix Xdebug bug #587 (http://bugs.xdebug.org/view.php?id=587) 
I need to have access to module_initialized which is currently a static 
in main/main.c. I've added a simple function to retrieve that and would 
like to commit that to 5.3/5.4 and trunk. Comments?
The patch is attached.

cheers,
Derick

-- 
http://derickrethans.nl | http://xdebug.org
Like Xdebug? Consider a donation: http://xdebug.org/donate.php
twitter: @derickr and @xdebug

---

## #53563 — Stas Malyshev — 2011-06-24T02:32:51+00:00

URL: https://externals.io/message/53560#53563 · In reply to: #53560

Hi!


> Hi!
>
> In order to fix Xdebug bug #587 (http://bugs.xdebug.org/view.php?id=587)
> I need to have access to module_initialized which is currently a static
> in main/main.c. I've added a simple function to retrieve that and would
> like to commit that to 5.3/5.4 and trunk. Comments?
> The patch is attached.

Doesn't seem to do any harm, though adding it in 5.3 would mean that 
some xdebug builds would work only with 5.3.7 but not 5.3.6, unless you 
do some magic. For 5.4, I think it's fine.
-- 
Stanislav Malyshev, Software Architect
SugarCRM: http://www.sugarcrm.com/
(408)454-6900 ext. 227

---

## #53572 — Derick Rethans — 2011-06-24T11:19:55+00:00

URL: https://externals.io/message/53560#53572 · In reply to: #53563

> 
> > […]
> 
> Doesn't seem to do any harm, though adding it in 5.3 would mean that 
> some xdebug builds would work only with 5.3.7 but not 5.3.6, unless 
> you do some magic. For 5.4, I think it's fine.

Makes sense, committed to 5.4 and trunk.

Derick

---

## #53574 — johannes@schlueters.de — 2011-06-24T12:26:56+00:00

URL: https://externals.io/message/53560#53574 · In reply to: #53560

> Hi!
> 
> In order to fix Xdebug bug #587 (http://bugs.xdebug.org/view.php?id=587) 
> I need to have access to module_initialized which is currently a static 
> in main/main.c. I've added a simple function to retrieve that and would 
> like to commit that to 5.3/5.4 and trunk. Comments?
> The patch is attached.

I know the variable uses singular, but maybe
php_get_modules_initialized() is clearer?

johannes

---

## #53576 — Derick Rethans — 2011-06-24T17:09:55+00:00

URL: https://externals.io/message/53560#53576 · In reply to: #53574

> 
> > […]
> 
> I know the variable uses singular, but maybe
> php_get_modules_initialized() is clearer?

But afaik, it means PHP as "module", so plural makes little sense to me?

cheers,
Derick
-- 
http://derickrethans.nl | http://xdebug.org
Like Xdebug? Consider a donation: http://xdebug.org/donate.php
twitter: @derickr and @xdebug

---

## #53580 — Dmitry Stogov — 2011-06-25T06:12:21+00:00

URL: https://externals.io/message/53560#53580 · In reply to: #53560

Hi Derick,

I don't see any problems committing it.

Thanks. Dmitry.


> Hi!
> 
> In order to fix Xdebug bug #587 (http://bugs.xdebug.org/view.php?id=587)
> I need to have access to module_initialized which is currently a static
> in main/main.c. I've added a simple function to retrieve that and would
> like to commit that to 5.3/5.4 and trunk. Comments?
> The patch is attached.
> 
> cheers,
> Derick

---

## #53581 — Pierre Joye — 2011-06-25T09:01:32+00:00

URL: https://externals.io/message/53560#53581 · In reply to: #53576

2011/6/24 Derick Rethans <derick@php.net>:
> 
>
> > […]
>
> But afaik, it means PHP as "module", so plural makes little sense to me?

It is more about the SAPI than SAPI only available as module. I would
add sapi in the function as well to avoid any confusion.
php_sapi_get_module_initialized.

Cheers,
-- 
Pierre

@pierrejoye | http://blog.thepimp.net | http://www.libgd.org
