summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Vlasenko2008-01-28 09:39:30 +0000
committerDenis Vlasenko2008-01-28 09:39:30 +0000
commit0effc2410b219de8c1966752ed217d67943fce69 (patch)
treefd2fce34aa42d0668f5da5e101ae1ca650c63354
parentb5c60fc7870a66d89de571e96596b0745edcd6d9 (diff)
downloadbusybox-0effc2410b219de8c1966752ed217d67943fce69.zip
busybox-0effc2410b219de8c1966752ed217d67943fce69.tar.gz
microcom: undo #define trick, gcc fails to take advantage of it
-rw-r--r--miscutils/microcom.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/miscutils/microcom.c b/miscutils/microcom.c
index 160bff1..00a4983 100644
--- a/miscutils/microcom.c
+++ b/miscutils/microcom.c
@@ -45,8 +45,8 @@ int microcom_main(int argc, char **argv)
{
struct pollfd pfd[2];
int nfd;
- //int sfd;
-#define sfd (pfd[0].fd)
+ int sfd;
+/* #define sfd (pfd[0].fd) - gcc 4.2.1 is still not smart enough */
char *device_lock_file;
const char *opt_s = "9600";
speed_t speed;
@@ -123,7 +123,7 @@ int microcom_main(int argc, char **argv)
goto restore0_close_unlock_and_exit;
// main loop: check with poll(), then read/write bytes across
- /* pfd[0].fd = sfd; - they are the same */
+ pfd[0].fd = sfd;
pfd[0].events = POLLIN;
pfd[1].fd = STDIN_FILENO;
pfd[1].events = POLLIN;