Giter Club home page Giter Club logo

ruby-imagespec's People

Contributors

andersonbrandon avatar dim avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

ruby-imagespec's Issues

Bug fix for Exif JPEGS

When a JPEG contains a Exif header, the parser gets into troubles. This bug fix may solve the problem:

in JPEG.rb

  def self.detected?(stream)
    stream.rewind
    case stream.read(10)
      when /^\xff\xd8\xff\xe0\x00\x10JFIF/ then true
      when /^\xff\xd8\xff\xe1/ && /Exif$/  then true # bug fix, cannot do match *
      # when /^\xff\xd8\xff\xe1(.*){1}Exif/  then true
      else false
    end
  end

Segmentation Fault in swf parser

Got this with apache2 / passenger and ruby 1.8.6 and a 1.7 MB swf.

<RAILS_ROOT>/plugins/image_spec/lib/parsers/swf.rb:41: [BUG] Segmentation fault
ruby 1.8.6 (2008-03-03) [i686-linux]

The segfault happens here, at line 41 in swf.rb :

    # And reconstruct the stream contents to the first 8 bytes (header)
    # Plus our decompressed body
    contents = contents[0..7] + body

I think this is not really needed since following code does not use the header bytes anymore.
I fixed this in my own copy, but I'm sorry i'm not a regular git user, so I do not know how to commit my patch as for now.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.