Merge pull request #681 from th-h/thh-limit
Set empty limit to "" in serendipity_fetchEntries.
This commit is contained in:
commit
599aeef3b6
@ -1,6 +1,8 @@
|
||||
Version 2.4-alpha1 ()
|
||||
------------------------------------------------------------------------
|
||||
|
||||
* Fix: Force empty limit to "" in serendipity_fetchEntries().
|
||||
|
||||
* Fix: Escape version string in update notifier to avoid XSS.
|
||||
|
||||
* Fix: Prevent renaming a ML object into an existing file,
|
||||
|
@ -435,6 +435,15 @@ function &serendipity_fetchEntries($range = null, $full = true, $limit = '', $fe
|
||||
}
|
||||
|
||||
$limit = serendipity_db_limit_sql($limit);
|
||||
|
||||
} else {
|
||||
# if $limit was empty(), no limit was set;
|
||||
# but empty() may also mean FALSE, "" or 0,
|
||||
# so set it to "" to remove the LIMIT
|
||||
# statement completely; should catch errors
|
||||
# with a limit of 0 and some database drivers
|
||||
# see <https://github.com/s9y/Serendipity/issues/636>
|
||||
$limit = '';
|
||||
}
|
||||
|
||||
$query = "SELECT $select_key
|
||||
|
Loading…
x
Reference in New Issue
Block a user