Fixes import of binary data. This may not be a problem for valid imports, but at the least this avoids a stack trace
git-svn-id: file:///home/svn/framework3/trunk@13428 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
1fb64f099d
commit
b885b8ea74
|
@ -2060,8 +2060,9 @@ class DBManager
|
|||
return :libpcap
|
||||
end
|
||||
|
||||
# Text string kinds of data.
|
||||
if data and data.to_s.strip.size.zero?
|
||||
# This is a text string, lets make sure its treated as binary
|
||||
data = data.unpack("C*").pack("C*")
|
||||
if data and data.to_s.strip.length == 0
|
||||
raise DBImportError.new("The data provided to the import function was empty")
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue