mirror of
				https://github.com/vdr-projects/vdr.git
				synced 2025-03-01 10:50:46 +00:00 
			
		
		
		
	Fixed opening /dev/video in cDvbDevice::GrabImage() in case of NEWSTRUCT driver
This commit is contained in:
		| @@ -172,6 +172,7 @@ Andreas Schultz <aschultz@warp10.net> | |||||||
|  for adding cDevice::NewOsd() to allow a derived cDevice class to implement its own |  for adding cDevice::NewOsd() to allow a derived cDevice class to implement its own | ||||||
|  OSD capabilities |  OSD capabilities | ||||||
|  for implementing an SPU decoder |  for implementing an SPU decoder | ||||||
|  |  for fixing opening /dev/video in cDvbDevice::GrabImage() in case of NEWSTRUCT driver | ||||||
|  |  | ||||||
| Aaron Holtzman | Aaron Holtzman | ||||||
|  for writing 'ac3dec' |  for writing 'ac3dec' | ||||||
|   | |||||||
							
								
								
									
										2
									
								
								HISTORY
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								HISTORY
									
									
									
									
									
								
							| @@ -1473,3 +1473,5 @@ Video Disk Recorder Revision History | |||||||
|   Huelswitt). |   Huelswitt). | ||||||
| - The EPG now drops events from "other" streams that have a duration of 86400 | - The EPG now drops events from "other" streams that have a duration of 86400 | ||||||
|   seconds or more (this avoids bogus entries like "PROGRAMMES ALLEMANDS"). |   seconds or more (this avoids bogus entries like "PROGRAMMES ALLEMANDS"). | ||||||
|  | - Fixed opening /dev/video in cDvbDevice::GrabImage() in case of NEWSTRUCT | ||||||
|  |   driver (thanks to Andreas Schultz). | ||||||
|   | |||||||
| @@ -4,7 +4,7 @@ | |||||||
|  * See the main source file 'vdr.c' for copyright information and |  * See the main source file 'vdr.c' for copyright information and | ||||||
|  * how to reach the author. |  * how to reach the author. | ||||||
|  * |  * | ||||||
|  * $Id: dvbdevice.c 1.18 2002/09/15 11:24:18 kls Exp $ |  * $Id: dvbdevice.c 1.19 2002/09/15 13:12:25 kls Exp $ | ||||||
|  */ |  */ | ||||||
|  |  | ||||||
| #include "dvbdevice.h" | #include "dvbdevice.h" | ||||||
| @@ -200,7 +200,11 @@ cSpuDecoder *cDvbDevice::GetSpuDecoder(void) | |||||||
|  |  | ||||||
| bool cDvbDevice::GrabImage(const char *FileName, bool Jpeg, int Quality, int SizeX, int SizeY) | bool cDvbDevice::GrabImage(const char *FileName, bool Jpeg, int Quality, int SizeX, int SizeY) | ||||||
| { | { | ||||||
|   int videoDev = DvbOpen(DEV_VIDEO, CardIndex(), O_RDWR, true); |   char buffer[PATH_MAX]; | ||||||
|  |   snprintf(buffer, sizeof(buffer), "%s%d", DEV_VIDEO, CardIndex()); | ||||||
|  |   int videoDev = open(buffer, O_RDWR); | ||||||
|  |   if (videoDev < 0) | ||||||
|  |      LOG_ERROR_STR(buffer); | ||||||
|   if (videoDev >= 0) { |   if (videoDev >= 0) { | ||||||
|      int result = 0; |      int result = 0; | ||||||
|      struct video_mbuf mbuf; |      struct video_mbuf mbuf; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user