summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2014-05-21 09:40:41 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2014-06-23 16:41:05 -0700
commit2a9f12b4503c9b8deed2b1229877b978478a0b3b (patch)
tree1e13a819cfb5388bf7586f22333ce4101ad4ac80
parent6a9ed8cc9a4df568ee0df35964f87007bfc730df (diff)
downloadchef-2a9f12b4503c9b8deed2b1229877b978478a0b3b.tar.gz
convert to using ffi_yajl
-rw-r--r--lib/chef/knife/core/object_loader.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/chef/knife/core/object_loader.rb b/lib/chef/knife/core/object_loader.rb
index 1d207c10d1..de683b23fd 100644
--- a/lib/chef/knife/core/object_loader.rb
+++ b/lib/chef/knife/core/object_loader.rb
@@ -16,6 +16,8 @@
# limitations under the License.
#
+require 'ffi_yajl'
+
class Chef
class Knife
module Core
@@ -83,7 +85,7 @@ class Chef
def object_from_file(filename)
case filename
when /\.(js|json)$/
- r = Yajl::Parser.parse(IO.read(filename))
+ r = FFI_Yajl::Parser.parse(IO.read(filename))
# Chef::DataBagItem doesn't work well with the json_create method
if @klass == Chef::DataBagItem