なるようになるブログ

読書感想文かrailsについてかrubyについてか

rails commit log流し読み(2014/07/11)

2014/07/11分のコミットです。

CHANGELOGにのったコミットは以下の通りです。

actionpack/CHANGELOG.md


* gcampbell-rosetta_flash:

actionpack/lib/action_controller/metal/renderers.rbの修正です。

CVE-2014-4671("Rosetta Flash")の対応を行っています。

JSONP+Flashを使われている方は対応が必要ですね。CVE-2014-4671についてはこちらのブログ参考。


Removed single space padding from empty response body.

actionpack/lib/action_controller/metal/rendering.rbの修正です。

render nothing: true又は、nilをrenderした際、スペースを一つresponse bodyに設定していたのを、何も設定しないよう修正しています。

元々スペースを一つ設定していたのは、lengthが0だとSafariでエラーになるバグがあって、そのための対応だったとのですが、Safari側がそのバグを対応したので、rails側も対応したとの事です。

スペースを一つ返す元の動作を行いたい場合は、render body: ' 'とすればOK。


Fixed borken tests in AV caused by 013c74d

actionview/test/actionpack/controller/render_test.rbの修正です

上のコミットの対応でコケてしまっていたテストを修正しています。


Fix incorrect unsubscription.

railties/test/rack_logger_test.rbの修正です。

notifierのunsubscribe処理が正しく行われていなかったのを修正しています。


Synced 4.2 release notes with the latest commits.

guides/source/4_2_release_notes.mdの修正です。

4.2のrelease noteに最新のコミットを追記しています。


Use #bytesize instead of #size when checking for cookie overflow

actionpack/lib/action_dispatch/middleware/cookies.rbの修正です。

cookieに設定された値のoverflowチェックにString#sizeを使用していたのをString#bytesizeを使用するよう修正しています。

sizeだと文字数なので、正確なチェックが出来てなかったんですね。


[Guides] Sentence break for clarity [ci-skip]

rails guideのActive Record Validationsの修正です。

Custom Validatorsの説明を修正しています。文の区切りを明確にしています。


Use a type object for type casting behavior on SQLite3

activerecord/lib/active_record/connection_adapters/sqlite3_adapter.rbの修正です。

SQLite3のString型のcast処理を、type objectで行うよう修正しています。


Don't rely on the column SQL type for bit string quoting

PostgreSQLのConnectionAdapterの修正です。

Quotingで行っていたbit string型のクォート処理を、OID::Bit::Dataクラスで行うよう修正しています。