mirror of
				https://github.com/msgpack/msgpack-python.git
				synced 2025-11-04 03:20:56 +00:00 
			
		
		
		
	Merge pull request #31 from seliopou/master
Fix Unpacker example in README
This commit is contained in:
		
						commit
						1e17642264
					
				
					 1 changed files with 3 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -54,10 +54,11 @@ stream.
 | 
			
		|||
 | 
			
		||||
   unpacker = msgpack.Unpacker()
 | 
			
		||||
   while True:
 | 
			
		||||
       data = buf.read(4)
 | 
			
		||||
       data = buf.read(16)
 | 
			
		||||
       if not data:
 | 
			
		||||
           break
 | 
			
		||||
       unpacker.seed(buf.read(16))
 | 
			
		||||
       unpacker.feed(data)
 | 
			
		||||
 | 
			
		||||
       for unpacked in unpacker:
 | 
			
		||||
           print unpacked
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue