diff --git a/external/egf/hardware.h b/external/egf/hardware.h index c44dc4c..69dca1c 100644 --- a/external/egf/hardware.h +++ b/external/egf/hardware.h @@ -1,3 +1,4 @@ +// vim:tabstop=4 shiftwidth=4 syntax=objc /** * \file hardware.h * \brief Functions to query the underlying hardware. @@ -47,7 +48,6 @@ struct Hardware_info_t HW_FAMILY family; // Hardware family. char version; // Zero or positive means recognised version. char *name; // Hardware name as C string. - char udid[UDID_LEN + 1]; // UDID plus NULL terminator. }; @@ -56,5 +56,3 @@ void destroy_hardware_info(Hardware_info **info); #endif // __EGF_HARDWARE_H__ - -// vim:tabstop=4 shiftwidth=4 syntax=objc diff --git a/external/egf/hardware.m b/external/egf/hardware.m index 3a6d86d..e9b2954 100644 --- a/external/egf/hardware.m +++ b/external/egf/hardware.m @@ -1,4 +1,4 @@ -// vim:tabstop=4 shiftwidth=4 encoding=utf-8 syntax=objc +// vim:tabstop=4 shiftwidth=4 syntax=objc #include "egf/hardware.h" @@ -34,26 +34,12 @@ } info->name = calloc(1, size); if (!info->name) { - DLOG(@"Not enough memory to get hardware name (%lu).", size); + DLOG(@"Not enough memory to get hardware name (%ld).", size); free(info); info = 0; goto exit; } - info->udid[0] = 0; - UIDevice *dev = [UIDevice currentDevice]; - NSString *udid = dev.uniqueIdentifier; - if (udid) { - if (UDID_LEN == strlen([udid cStringUsingEncoding:1])) { - strncpy(info->udid, [udid cStringUsingEncoding:1], UDID_LEN); - info->udid[UDID_LEN] = 0; - } else { - DLOG(@"Unexpected UDID length for '%@'.", udid); - } - } else { - DLOG(@"Couldn't read UDID."); - } - sysctlbyname("hw.machine", info->name, &size, 0, 0); DLOG(@"Retrieved hardware string '%s'.", info->name); diff --git a/src/controllers/Share_tab.m b/src/controllers/Share_tab.m index 76fe6d8..74d40f3 100644 --- a/src/controllers/Share_tab.m +++ b/src/controllers/Share_tab.m @@ -271,10 +271,9 @@ - (NSString*)get_export_filename Hardware_info *info = get_hardware_info(); NSString *ret = [NSString stringWithFormat:@"positions %04d-%02d-%02d " - @"%02d:%02d:%02d %s %s", [now year], [now month], [now day], + @"%02d:%02d:%02d %s", [now year], [now month], [now day], [now hour], [now minute], [now second], - (info && info->name) ? (info->name) : ("unknown"), - (info && info->udid[0]) ? (info->udid) : ("no udid"), nil]; + (info && info->name) ? (info->name) : ("unknown"), nil]; destroy_hardware_info(&info); return ret;