WordPress/wp-includes
audrasjb 6371434821 Media: Prevent division by zero in wp_img_tag_add_width_and_height_attr().
This changesets adds a check for `$size_array` values to prevent a potential division by zero.
Follow-up to [57294].

Props jdekhtiar.
Fixes #61054.
See #59352.



Built from https://develop.svn.wordpress.org/trunk@58033


git-svn-id: http://core.svn.wordpress.org/trunk@57499 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2024-04-22 20:35:10 +00:00
..
assets
block-bindings
block-patterns
block-supports
blocks
certificates
css
customize
fonts
html-api
ID3
images
interactivity-api Interactivity API: Do not print state if it’s an empty array. 2024-03-15 12:12:09 +00:00
IXR
js Docs: Fix various typos and spelling mistakes. 2024-04-12 17:47:13 +00:00
l10n
php-compat
PHPMailer
pomo
Requests
rest-api
SimplePie
sitemaps
sodium_compat
style-engine
Text
theme-compat
widgets
admin-bar.php Toolbar: Polish design and code combining duplicate profile links. 2024-03-04 21:50:11 +00:00
atomlib.php
author-template.php
block-bindings.php
block-editor.php
block-i18n.json
block-patterns.php
block-template-utils.php
block-template.php
blocks.php Editor: Add fallback for block version when registering block script module 2024-02-21 11:20:10 +00:00
bookmark-template.php
bookmark.php
cache-compat.php
cache.php Cache API: Introduce wp_cache_supports() function. 2022-10-10 18:22:11 +00:00
canonical.php
capabilities.php
category-template.php
category.php
class-avif-info.php
class-feed.php
class-http.php
class-IXR.php
class-json.php
class-oembed.php
class-phpass.php
class-phpmailer.php Mail: Make sure the PHPMailer class is only required once if a plugin requires wp-includes/class-phpmailer.php directly. 2020-07-21 12:58:02 +00:00
class-pop3.php
class-requests.php
class-simplepie.php
class-smtp.php
class-snoopy.php
class-walker-category-dropdown.php
class-walker-category.php
class-walker-comment.php
class-walker-nav-menu.php
class-walker-page-dropdown.php
class-walker-page.php
class-wp-admin-bar.php Toolbar: Polish design and code combining duplicate profile links. 2024-03-04 21:50:11 +00:00
class-wp-ajax-response.php
class-wp-application-passwords.php
class-wp-block-bindings-registry.php
class-wp-block-bindings-source.php
class-wp-block-editor-context.php
class-wp-block-list.php Coding Standards: Correct equals sign alignment in various files. 2023-11-02 00:04:24 +00:00
class-wp-block-parser-block.php
class-wp-block-parser-frame.php
class-wp-block-parser.php
class-wp-block-pattern-categories-registry.php
class-wp-block-patterns-registry.php
class-wp-block-styles-registry.php
class-wp-block-supports.php
class-wp-block-template.php
class-wp-block-type-registry.php
class-wp-block-type.php
class-wp-block.php
class-wp-classic-to-block-menu-converter.php
class-wp-comment-query.php
class-wp-comment.php
class-wp-customize-control.php
class-wp-customize-manager.php
class-wp-customize-nav-menus.php
class-wp-customize-panel.php
class-wp-customize-section.php
class-wp-customize-setting.php
class-wp-customize-widgets.php
class-wp-date-query.php
class-wp-dependencies.php
class-wp-dependency.php
class-wp-duotone.php Editor: Prevent PHP warning when parsing duotone hue values. 2024-02-18 14:59:07 +00:00
class-wp-editor.php
class-wp-embed.php Docs: Replace multiple single line comments with multi-line comments. 2023-07-09 20:17:29 +00:00
class-wp-error.php
class-wp-fatal-error-handler.php
class-wp-feed-cache-transient.php
class-wp-feed-cache.php
class-wp-hook.php
class-wp-http-cookie.php
class-wp-http-curl.php
class-wp-http-encoding.php
class-wp-http-ixr-client.php Code Modernization: Add AllowDynamicProperties attribute to all (parent) classes. 2022-09-12 15:47:14 +00:00
class-wp-http-proxy.php
class-wp-http-requests-hooks.php
class-wp-http-requests-response.php
class-wp-http-response.php
class-wp-http-streams.php
class-wp-http.php
class-wp-image-editor-gd.php
class-wp-image-editor-imagick.php Coding Standards: Use strict comparison in wp-includes/class-wp-image-editor-imagick.php. 2024-04-06 13:37:18 +00:00
class-wp-image-editor.php Media: enable AVIF support. 2024-02-02 17:48:15 +00:00
class-wp-list-util.php
class-wp-locale-switcher.php
class-wp-locale.php
class-wp-matchesmapregex.php
class-wp-meta-query.php Docs: Typo corrections in class WP_Meta_Query. 2024-04-22 20:25:08 +00:00
class-wp-metadata-lazyloader.php
class-wp-navigation-fallback.php
class-wp-network-query.php
class-wp-network.php
class-wp-object-cache.php Docs: Fix typo in _validate_cache_id() description. 2023-03-14 16:55:19 +00:00
class-wp-oembed-controller.php
class-wp-oembed.php
class-wp-paused-extensions-storage.php Docs: Various improvements and corrections to inline documentation. 2024-02-16 21:47:12 +00:00
class-wp-plugin-dependencies.php Plugins: Remove extra space in a translatable string. 2024-03-08 14:34:11 +00:00
class-wp-post-type.php
class-wp-post.php
class-wp-query.php
class-wp-recovery-mode-cookie-service.php
class-wp-recovery-mode-email-service.php
class-wp-recovery-mode-key-service.php
class-wp-recovery-mode-link-service.php
class-wp-recovery-mode.php
class-wp-rewrite.php
class-wp-role.php
class-wp-roles.php
class-wp-script-modules.php Script Loader: Add new script_module_loader_src filter for the script module src. 2024-03-15 11:29:07 +00:00
class-wp-scripts.php
class-wp-session-tokens.php
class-wp-simplepie-file.php
class-wp-simplepie-sanitize-kses.php
class-wp-site-query.php
class-wp-site.php
class-wp-styles.php Code Modernization: Replace usage of strpos() with str_starts_with(). 2023-05-02 15:45:22 +00:00
class-wp-tax-query.php
class-wp-taxonomy.php
class-wp-term-query.php
class-wp-term.php
class-wp-text-diff-renderer-inline.php
class-wp-text-diff-renderer-table.php
class-wp-textdomain-registry.php
class-wp-theme-json-data.php
class-wp-theme-json-resolver.php
class-wp-theme-json-schema.php
class-wp-theme-json.php
class-wp-theme.php Themes: Cache block theme patterns in a transient. 2024-04-19 17:59:16 +00:00
class-wp-user-meta-session-tokens.php
class-wp-user-query.php Query: Remove leading whitespace from certain database queries. 2024-03-02 13:38:07 +00:00
class-wp-user-request.php
class-wp-user.php
class-wp-walker.php
class-wp-widget-factory.php
class-wp-widget.php
class-wp-xmlrpc-server.php
class-wp.php
class-wpdb.php
class.wp-dependencies.php
class.wp-scripts.php
class.wp-styles.php Coding Standards: Rename WordPress Dependencies API class files. 2022-09-20 14:17:12 +00:00
comment-template.php
comment.php General: Consistently cast return value to int in functions that use ceil(). 2024-02-17 15:24:08 +00:00
compat.php
cron.php Docs: Replace "sanity" with "confidence" for inclusive language. 2024-01-03 21:59:19 +00:00
date.php
default-constants.php Docs: Correct @since version for COOKIE_DOMAIN default value change. 2024-04-17 09:46:19 +00:00
default-filters.php
default-widgets.php
deprecated.php General: Fix various typo issues found in deprecated.php and Font Library unit tests. 2024-04-01 20:45:13 +00:00
embed-template.php
embed.php
error-protection.php
feed-atom-comments.php
feed-atom.php Feeds: Remove reference to wp-atom.php in Atom feeds xml:base attribute. 2021-11-29 09:52:00 +00:00
feed-rdf.php
feed-rss2-comments.php
feed-rss2.php
feed-rss.php
feed.php
fonts.php
formatting.php
functions.php
functions.wp-scripts.php
functions.wp-styles.php
general-template.php
global-styles-and-settings.php
http.php
https-detection.php
https-migration.php
kses.php
l10n.php
link-template.php
load.php
locale.php Docs: Add missing @deprecated tags in the file docblock of some deprecated files. 2019-10-08 17:19:04 +00:00
media-template.php
media.php Media: Prevent division by zero in wp_img_tag_add_width_and_height_attr(). 2024-04-22 20:35:10 +00:00
meta.php
ms-blogs.php
ms-default-constants.php Docs: Replace multiple single line comments with multi-line comments. 2023-07-10 22:48:22 +00:00
ms-default-filters.php
ms-deprecated.php
ms-files.php
ms-functions.php
ms-load.php
ms-network.php Cache API: Add helper function wp_cache_set_last_changed. 2023-05-02 11:26:24 +00:00
ms-settings.php
ms-site.php
nav-menu-template.php
nav-menu.php
option.php
pluggable-deprecated.php
pluggable.php
plugin.php
post-formats.php
post-template.php
post-thumbnail-template.php
post.php Docs: Fix various typos and spelling mistakes. 2024-04-12 17:47:13 +00:00
query.php
registration-functions.php
registration.php
rest-api.php
revision.php
rewrite.php
robots-template.php
rss-functions.php
rss.php
script-loader.php
script-modules.php
session.php Code Modernization: Replace dirname( __FILE__ ) calls with __DIR__ magic constant. 2020-02-06 06:33:11 +00:00
shortcodes.php
sitemaps.php Docs: Miscellaneous DocBlock corrections. 2021-05-15 17:38:05 +00:00
spl-autoload-compat.php
style-engine.php
taxonomy.php Docs: Various improvements and corrections to inline documentation. 2024-02-16 21:47:12 +00:00
template-canvas.php
template-loader.php
template.php
theme-i18n.json
theme-previews.php
theme-templates.php
theme.json
theme.php
update.php Coding Standards: Include one space after function keyword for closures. 2023-09-12 15:23:18 +00:00
user.php
vars.php Permalinks: Detect FrankenPHP web server support. 2024-04-04 13:40:06 +00:00
version.php Media: Prevent division by zero in wp_img_tag_add_width_and_height_attr(). 2024-04-22 20:35:10 +00:00
widgets.php
wp-db.php
wp-diff.php Code Modernization: Replace dirname( __FILE__ ) calls with __DIR__ magic constant. 2020-02-06 06:33:11 +00:00