url_fskip: Return an error code if the url_fseek failed
Originally committed as revision 24277 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
		
							parent
							
								
									5c32755570
								
							
						
					
					
						commit
						d5e9ddeb73
					
				@ -358,8 +358,9 @@ int64_t url_fseek(ByteIOContext *s, int64_t offset, int whence);
 | 
				
			|||||||
/**
 | 
					/**
 | 
				
			||||||
 * Skip given number of bytes forward.
 | 
					 * Skip given number of bytes forward.
 | 
				
			||||||
 * @param offset number of bytes
 | 
					 * @param offset number of bytes
 | 
				
			||||||
 | 
					 * @return 0 on success, <0 on error
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
void url_fskip(ByteIOContext *s, int64_t offset);
 | 
					int url_fskip(ByteIOContext *s, int64_t offset);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
 * ftell() equivalent for ByteIOContext.
 | 
					 * ftell() equivalent for ByteIOContext.
 | 
				
			||||||
 | 
				
			|||||||
@ -182,9 +182,10 @@ int64_t url_fseek(ByteIOContext *s, int64_t offset, int whence)
 | 
				
			|||||||
    return offset;
 | 
					    return offset;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void url_fskip(ByteIOContext *s, int64_t offset)
 | 
					int url_fskip(ByteIOContext *s, int64_t offset)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    url_fseek(s, offset, SEEK_CUR);
 | 
					    int64_t ret = url_fseek(s, offset, SEEK_CUR);
 | 
				
			||||||
 | 
					    return ret < 0 ? ret : 0;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
int64_t url_ftell(ByteIOContext *s)
 | 
					int64_t url_ftell(ByteIOContext *s)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user