Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mdmngr
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
IOPSYS
mdmngr
Commits
c244cd7d
Commit
c244cd7d
authored
7 years ago
by
Jakob Olsson
Browse files
Options
Downloads
Patches
Plain Diff
move debug from library to application
parent
901996e3
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
common.h
+8
-0
8 additions, 0 deletions
common.h
dongle.c
+1
-0
1 addition, 0 deletions
dongle.c
libmobile.h
+1
-11
1 addition, 11 deletions
libmobile.h
with
10 additions
and
11 deletions
common.h
+
8
−
0
View file @
c244cd7d
...
@@ -20,6 +20,14 @@
...
@@ -20,6 +20,14 @@
#include
<libubox/blobmsg.h>
#include
<libubox/blobmsg.h>
#include
<libubus.h>
#include
<libubus.h>
extern
int
debug
;
#define debug_print(...) \
do \
{ \
if (debug) \
fprintf(stderr, __VA_ARGS__); \
} while (0)
/**
/**
* Function: print_to_ubus
* Function: print_to_ubus
*
*
...
...
This diff is collapsed.
Click to expand it.
dongle.c
+
1
−
0
View file @
c244cd7d
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
#include
"dongle_network.h"
#include
"dongle_network.h"
struct
ubus_context
*
ctx
;
struct
ubus_context
*
ctx
;
int
debug
;
static
struct
option
long_options
[]
=
static
struct
option
long_options
[]
=
{
{
...
...
This diff is collapsed.
Click to expand it.
libmobile.h
+
1
−
11
View file @
c244cd7d
...
@@ -4,16 +4,6 @@
...
@@ -4,16 +4,6 @@
#include
<json-c/json.h>
#include
<json-c/json.h>
#include
<string.h>
#include
<string.h>
int
debug
;
//#define DEBUG 1 //how to define from some sort of config? there is no main?
#define debug_print(...) \
do \
{ \
if (debug) \
fprintf(stderr, __VA_ARGS__); \
} while (0)
/***************************************************
/***************************************************
* Libmobile - A 4G Dongle library
* Libmobile - A 4G Dongle library
*
*
...
@@ -269,4 +259,4 @@ struct json_object *mobile_set_pin(char *current_pin, char *new_pin);
...
@@ -269,4 +259,4 @@ struct json_object *mobile_set_pin(char *current_pin, char *new_pin);
* NULL on failure.
* NULL on failure.
*/
*/
struct
json_object
*
mobile_disable_pin
(
char
*
pin
);
struct
json_object
*
mobile_disable_pin
(
char
*
pin
);
#endif
#endif
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment