Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
65255e8c
Commit
65255e8c
authored
Feb 26, 2010
by
Max Kanat-Alexander
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 547601: Make the JSON-RPC interface return UTF-8 data correctly.
r=dkl, a=mkanat
parent
083187a2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
JSONRPC.pm
Bugzilla/WebService/Server/JSONRPC.pm
+12
-2
No files found.
Bugzilla/WebService/Server/JSONRPC.pm
View file @
65255e8c
...
...
@@ -35,13 +35,23 @@ sub new {
Bugzilla
->
_json_server
(
$self
);
$self
->
dispatch
(
WS_DISPATCH
);
$self
->
return_die_message
(
1
);
$self
->
json
->
allow_blessed
(
1
);
$self
->
json
->
convert_blessed
(
1
);
# Default to JSON-RPC 1.0
$self
->
version
(
0
);
return
$self
;
}
sub
create_json_coder
{
my
$self
=
shift
;
my
$json
=
$self
->
SUPER::
create_json_coder
(
@_
);
$json
->
allow_blessed
(
1
);
$json
->
convert_blessed
(
1
);
# This may seem a little backwards, but what this really means is
# "don't convert our utf8 into byte strings, just leave it as a
# utf8 string."
$json
->
utf8
(
0
)
if
Bugzilla
->
params
->
{
'utf8'
};
return
$json
;
}
# Override the JSON::RPC method to return our CGI object instead of theirs.
sub
cgi
{
return
Bugzilla
->
cgi
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment