New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

**[FIX]** for bug "failed to load image: ../icon/home.png" (issue #995) (Linux and Windows) #1050

Open
wants to merge 4 commits into
base: master
from

Conversation

Projects
None yet
3 participants
@ShouryaAggarwal

ShouryaAggarwal commented Dec 7, 2018

Please prefix your pull request with one of the following: [FEATURE] [FIX] [IMPROVEMENT].

In raising this pull request, I confirm the following (please check boxes):

  • I have read and understood the contributors guide.
  • I have checked that another pull request for this purpose does not exist. (I knew about a 2 months old pull request mentioned in comments of bug and just found out about another pull request, was 5 days old and had errors but fixed for mac and windows. I'm open to collab)
  • I have considered, and confirmed that this submission will be valuable to others.
  • I accept that this submission may not be used, and the pull request closed at the will of the maintainer.
  • I give this submission freely, and claim no ownership to its content.
  • I have mentioned this change in the changelog. --- Changelog's format was according to releases and dates, I didn't understand where to put this small bug fix, under which date or release.

My familiarity with the project is as follows (check one):

  • I have never used CCExtractor.
  • I have used CCExtractor just a couple of times.
  • I absolutely love CCExtractor, but have not contributed previously.
  • I am an active contributor to CCExtractor.

Fixed the mentioned bug (issue #995) for lunix and windows. Tested properly on linux but not so greatly on windows.

ShouryaAggarwal added some commits Dec 7, 2018

Modified src/ccextractorGUI.c to be able to run the GUI from any othe…
…r directory than the one holding the executable
@ccextractor-bot

This comment has been minimized.

Collaborator

ccextractor-bot commented Dec 7, 2018

CCExtractor CI platform finished running the test files on linux. Below is a summary of the test results:

Report Name Tests Passed
Broken 12/13
DVB 4/7
DVR-MS 2/2
General 27/27
Hauppage 3/3
MP4 3/3
NoCC 10/10
Teletext 14/21
WTV 13/13
XDS 34/34
CEA-708 14/14
DVD 3/3
Options 81/86

It seems that not all tests were passed completely. This is an indication that the output of some files is not as expected (but might be according to you).

Your PR breaks these cases:


Check the result page for more info.
@cfsmp3

The same thing is copied many times over and over. Instead of doing a strcpy(), strcat() and then an icon_load() why not have a function that takes the icon name and those all those things and returns whatever icon_load() returns?

@ccextractor-bot

This comment has been minimized.

Collaborator

ccextractor-bot commented Dec 7, 2018

CCExtractor CI platform finished running the test files on windows. Below is a summary of the test results:

Report Name Tests Passed
Broken 13/13
DVB 3/7
DVR-MS 2/2
General 27/27
Hauppage 3/3
MP4 3/3
NoCC 10/10
Teletext 21/21
WTV 13/13
XDS 34/34
CEA-708 14/14
DVD 3/3
Options 85/86

It seems that not all tests were passed completely. This is an indication that the output of some files is not as expected (but might be according to you).

Your PR breaks these cases:

  • ccextractor -datapid 5603 -autoprogram -out=srt -latin1 -teletext 85c7fc1ad7...
  • ccextractor -autoprogram -out=srt -latin1 85271be4d2...
  • ccextractor --capfile /repository/Dictionary/MattS_dictionary.txt c83f765c66...
  • ccextractor -stdout -quiet -nofc -nodvbcolor 79a51f3500...
  • ccextractor -stdout -quiet -nofc -nodvbcolor 767b546f96...

Check the result page for more info.
@ShouryaAggarwal

This comment has been minimized.

ShouryaAggarwal commented Dec 7, 2018

@cfsmp3 I made a function to get the icon address from icon name, so what it returns is passed the parameter to icon_load for different icons.

@cfsmp3

This comment has been minimized.

Contributor

cfsmp3 commented Dec 7, 2018

@ShouryaAggarwal this causes the problem that you're using a global variable so now your function is no longer thread_safe.

Instead just write a function that generates the path and loads the icon (and then returns that) rather than one function to create the path, returns it from a static variable...

@ShouryaAggarwal

This comment has been minimized.

ShouryaAggarwal commented Dec 8, 2018

@cfsmp3 thanks for pointing out the thread safe aspect. I've done the necessary changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment