| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Factor out the i18n definitions into i18n.h include files:
One include file each for libgphoto2 and for libgphoto2_port.
This removes the complete
#ifdef ENABLE_NLS
# include <libintl.h>
# undef _
# define _(String) dgettext (GETTEXT_PACKAGE, String)
# ifdef gettext_noop
# define N_(String) gettext_noop (String)
# else
# define N_(String) (String)
# endif
#else
# define _(String) (String)
# define N_(String) (String)
#endif
block (which in some occasions defines even more macros)
and replaces it with a single line
#include "libgphoto2/i18n.h"
for camlibs and libgphoto2 itself and with
#include "libgphoto2_port/i18n.h"
for iolibs and libgphoto2_port itself.
This gives us two central locations to change the defintions.
|
|
|
|
| |
https://github.com/gphoto/libgphoto2/issues/633
|
| |
|
|
|
|
| |
https://github.com/gphoto/libgphoto2/issues/633
|
|
|
|
| |
Resolves signed-unsigned comparison issues.
|
| |
|
|
|
|
| |
fixes https://github.com/gphoto/libgphoto2/issues/502
|
| |
|
|
|
|
| |
fixes https://github.com/gphoto/libgphoto2/issues/234
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit rework the ptp2 event (irq) manager for multiple purposes:
- If the callback of an event is called because the async event
encountered an error, report this error upstream.
This allows a call to check_event to detect that a device was removed.
Without it, a call to check event will silentely hide that the
check_event call failed because a device being removed or dead (by
returning a TIMEOUT error) as if everything was ok but there was no
event.
- Re-arm async event requests if less are running than the expected
number of active interrupts transfers
- Use a linked list for the queue of events instead of a memory array
and steal buffers to avoid useless memory copies.
So the code should be faster and more memory efficient.
|
| |
|
| |
|
|
|
|
| |
case, as it might be -1
|
|
|
|
| |
CID 1033377 Resource leak
|
| |
|
|
|
|
| |
to clear them off the queue
|
| |
|
| |
|
| |
|
|
|
|
| |
and the irqcount on _close (we might just reopen the same port later).
|
| |
|
| |
|
|
|
|
| |
trigger
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15463 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15462 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
hang
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15459 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15441 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15412 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15411 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
|
|
|
| |
1) I always got an "invalid parameter" error message on gp_camera_exit,
because gp_port_close gets called twice. Since the result gets ignored
anyway the attached patch makes libusb1.c accept a second call by simply
returning.
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15403 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15393 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
interrupt transfer can be done in sync fashion, it will call into
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15389 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15385 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15384 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15382 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
started adding async transfers for e.g. interrupts
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15381 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
seem to do it.
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15258 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
|
|
|
|
| |
condense gp_log_data debug output.
- changed gp_log_data to take a printf style debug string
-> new major version of libgphoto2_port
- adjusted all callers
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15175 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
|
|
|
|
| |
I had something 'prepared' for this situation, here you go.. ;)
The patch does not, however, actually remove the GP_LOG_VERBOSE enum,
since that would change the interface for all clients, which might not
be worth it. If you don't think that is a problem, please remove it...
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15107 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
here are the logging cleanup patches for the remaining libgphoto_port
backend libs, that I announced earlier.
14 and 15 are equivalent to 3,4,5 as before.
16 removes 4 left instances of _(...) macro usage in log messages.
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15106 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1) introduce C_PARAMS and C_PARAMS_MSG along the lines of C_MEM
2) replace CHECK_NULL with C_PARAMS
3) replace the pattern
if ( something ) return GP_ERROR_BAD_PARAMETERS;
with
C_PARAMS ( !something );
I went over the whole patch again to check that each 'something'
condition is really inverted, so I dare to suggest you don't have to
do that again ;).
4) replaced CHECK_LIST and CHECK_INDEX_RANGE with simple one-line
C_PARAMS(...) expressions
5) a couple of hunks look like this
- if (!inet_aton (buffer, &inp)) {
- fprintf(stderr,"failed to scan for addr in %s\n", buffer);
- return GP_ERROR_BAD_PARAMETERS;
- }
+ C_PARAMS_MSG (inet_aton (buffer, &inp),
so some 'lost' error messages get now properly piped into the gp_log
mechanism.
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15103 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
|
|
|
| |
here is a patch for (mostly) consistent usage of a generalized C_MEM
macro for checking the return values of memory allocating functions,
i.e. malloc, calloc, realloc and strdup. It is the C_MEM from
libusb1.c, moved to gphoto2-port-log.h.
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15096 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
| |
adjust log_on_libusb_error_helper macro call
to log the location better
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15095 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15094 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15092 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
CHECK -> C_GP, added some more checks
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15091 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
|
| |
replace libusb1 error handling with macro code, handle
more errors in generic wrapper
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15090 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
use macros in argument and post-alloc checking.
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15088 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
| |
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@15023 67ed7778-7388-44ab-90cf-0a291f65f57c
|
|
|
|
|
|
|
| |
system. handle missing usb support in gp_port_usb_update
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@14957 67ed7778-7388-44ab-90cf-0a291f65f57c
|