mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 04:43:34 +08:00
getprogname: rename to px4_get_taskname
This commit is contained in:
@@ -108,7 +108,7 @@ int px4_task_delete(int pid)
|
||||
return task_delete(pid);
|
||||
}
|
||||
|
||||
const char *getprogname(void)
|
||||
const char *px4_get_taskname(void)
|
||||
{
|
||||
#if CONFIG_TASK_NAME_SIZE > 0
|
||||
FAR struct tcb_s *thisproc = sched_self();
|
||||
|
||||
@@ -388,7 +388,7 @@ unsigned long px4_getpid()
|
||||
return (unsigned long)pthread_self();
|
||||
}
|
||||
|
||||
const char *getprogname()
|
||||
const char *px4_get_taskname()
|
||||
{
|
||||
pthread_t pid = pthread_self();
|
||||
const char *prog_name = "UnknownApp";
|
||||
|
||||
@@ -134,7 +134,8 @@ __EXPORT bool px4_task_is_running(const char *taskname);
|
||||
__EXPORT int px4_prctl(int option, const char *arg2, unsigned pid);
|
||||
#endif
|
||||
|
||||
__EXPORT const char *getprogname(void);
|
||||
/** return the name of the current task */
|
||||
__EXPORT const char *px4_get_taskname(void);
|
||||
|
||||
__END_DECLS
|
||||
|
||||
|
||||
@@ -348,7 +348,7 @@ unsigned long px4_getpid()
|
||||
}
|
||||
|
||||
|
||||
const char *getprogname()
|
||||
const char *px4_get_taskname()
|
||||
{
|
||||
pthread_t pid = pthread_self();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user